JavaScript Events¶
Multiple custom JavaScript events allow to react with own JavaScript on JavaScript which is executed after certain user actions.
List of events¶
The following events exists:
Event name |
User action which triggers the event |
---|---|
|
A BE variant of a product was chosen. |
|
The country of billing or shipping address is updated. |
|
The currency of the cart is updated. |
|
The success/error message after adding a product to the cart will be hidden. |
|
A product is added to the cart (which updates the mini cart). |
|
A product is added to the cart which renders a success (or error) message. |
|
Another payment option is chosen. |
|
Another shipping option is chosen. |
Tip
The best way to understand when the event is executed and which data it
contains can be seen in it's context. Search in the directory
/Build/Sources/
for the event name.
How to listen for events¶
Every event comes with a detail object which contains data relevant for this specific event.
The following example shows how to listen for an event.