mirror of
https://github.com/esphome/esphome.git
synced 2025-10-24 04:33:49 +01:00
Optionally show internal components on the web server (#2627)
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>
This commit is contained in:
@@ -58,6 +58,12 @@ class WebServer : public Controller, public Component, public AsyncWebHandler {
|
||||
*/
|
||||
void set_js_include(const char *js_include);
|
||||
|
||||
/** Determine whether internal components should be displayed on the web server.
|
||||
* Defaults to false.
|
||||
*
|
||||
* @param include_internal Whether internal components should be displayed.
|
||||
*/
|
||||
void set_include_internal(bool include_internal) { include_internal_ = include_internal; }
|
||||
/** Set whether or not the webserver should expose the OTA form and handler.
|
||||
*
|
||||
* @param allow_ota.
|
||||
@@ -188,6 +194,7 @@ class WebServer : public Controller, public Component, public AsyncWebHandler {
|
||||
const char *css_include_{nullptr};
|
||||
const char *js_url_{nullptr};
|
||||
const char *js_include_{nullptr};
|
||||
bool include_internal_{false};
|
||||
bool allow_ota_{true};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user