mirror of
https://github.com/esphome/esphome.git
synced 2025-10-24 04:33:49 +01:00
Add support for button entities (#2824)
This commit is contained in:
@@ -112,6 +112,11 @@ class WebServer : public Controller, public Component, public AsyncWebHandler {
|
||||
std::string switch_json(switch_::Switch *obj, bool value);
|
||||
#endif
|
||||
|
||||
#ifdef USE_BUTTON
|
||||
/// Handle a button request under '/button/<id>/press'.
|
||||
void handle_button_request(AsyncWebServerRequest *request, const UrlMatch &match);
|
||||
#endif
|
||||
|
||||
#ifdef USE_BINARY_SENSOR
|
||||
void on_binary_sensor_update(binary_sensor::BinarySensor *obj, bool state) override;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user