OpenDTU-old/include/WebApi_webapp.h
Stefan Oberhumer e752c433af Use http header ETag caching for all static content.
Using the md5sum as ETag http header value should enable caching on all static http content.
2024-01-30 00:35:23 +01:00

15 lines
435 B
C++

// SPDX-License-Identifier: GPL-2.0-or-later
#pragma once
#include <ESPAsyncWebServer.h>
#include <TaskSchedulerDeclarations.h>
class WebApiWebappClass {
public:
void init(AsyncWebServer& server, Scheduler& scheduler);
private:
AsyncWebServer* _server;
void responseBinaryDataWithETagCache(AsyncWebServerRequest* request, const String &contentType, const String &contentEncoding, const uint8_t *content, size_t len);
};