Events
Events can be subscribed in the widget code in the same way
as adding parameters, using the cbk(key, value)
method.
#
onNavigate eventThis event is triggered when a navigation is made, either by user interaction or by an automatic event. This also represents a change in the hash url.
The navigation
argument will be an object with the following structure.
note
When this event is triggered the widget will automatically send page view events to Meta Pixel and Google Analytics, if they are present on the page.
#
onReserved eventThis event is triggered when a time slot is reserved. If this parameter is set, the specified method will be run with the booking properties as the only argument.
The booking
argument will be an object with the following structure.
note
A time slot is reserved when user has selected a time and entered their customer details. If the booking is not completed within 5 minutes, the time slot will be released.
#
onCompleted eventThis event is triggered when a booking is completed. If this parameter is set, the specified method will be run with the booking properties as the only argument.
The booking
argument will be an object with the following structure.
note
When this event is triggered the widget will automatically send purchase events to Meta Pixel and Google Analytics, if they are present on the page.