Callbacks allow for a cleaner management of button events.
The code was initially shared in Dean Blackketter (@blackketter) repository at https://github.com/blackketter/Switch
The credit for this code (callbacks) goes to @seanlano (https://github.com/blackketter/Switch/pull/2)
Merging this pull-request is compatible with the one "add_esp_compatibility"
Callbacks allow for a cleaner management of button events. The code was initially shared in Dean Blackketter (@blackketter) repository at https://github.com/blackketter/Switch