React to events
You will learn how responding to application or user events is the only way cause side effects and update the state of your components.
Listening to user events
![Interactivity is what transforms your toddle project from a static website to a full-scale dynamic web app. Clicks on reactive events gives the user feedback.](http://images.ctfassets.net/lizv2opdd3ay/6qi5f87lpscQaOjBIQCGA9/d09c3c6b7060f965ea2d94b38838d863/CleanShot_2023-10-13_at_13.04.12_2x.png)
Application events
-
`onLoad`: This is useful for triggering actions as soon as the element is loaded -
`onAttributeChange` is valid for triggering actions in response to an attribute change. For example, it could reload an API with new data when an attribute changes.
Declaring component events
Event Workflows