1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-01 10:52:19 +01:00

[online_image] Last-Modified-Date and ETag response caching (#8782)

This commit is contained in:
Craig Andrews
2025-05-28 01:17:57 -04:00
committed by GitHub
parent 04ee1a87e9
commit 1911269dc9
4 changed files with 43 additions and 8 deletions

View File

@@ -11,6 +11,13 @@ online_image:
format: PNG
type: BINARY
resize: 50x50
on_download_finished:
lambda: |-
if (cached) {
ESP_LOGD("online_image", "Cache hit: using cached image");
} else {
ESP_LOGD("online_image", "Cache miss: fresh download");
}
- id: online_binary_transparent_image
url: http://www.libpng.org/pub/png/img_png/pnglogo-blk-tiny.png
type: BINARY