Event listeners
Event listeners are JavaScript methods that set up a function to run whenever the specified event is delivered to the target.
You can use event listeners to provide UI feedback to your end-users, handle retries, and more. Since custom events do not support callbacks, event listeners give you access to the current status (loading, success, error) of any action carried out.
didomi:save-pending-consents-loading
didomi:save-pending-consents-loading
is triggered when the "save pending consents" action is waiting for SDK response.
didomi:save-pending-consents-error
didomi:save-pending-consents-error
is triggered when saving pending consents fails.
didomi:save-pending-consents-success
didomi:save-pending-consents-success
is triggered when saving pending consents succeeds.
didomi:set-consents-loading
didomi:set-consents-loading
is triggered when saving consents is waiting for SDK response.
didomi:set-consents-error
didomi:set-consents-error
is triggered when saving consents fails.
didomi:set-consents-success
didomi:set-consents-success
is triggered when saving consents succeeds.
didomi:send-authentication-loading
didomi:send-authentication-loading
is triggered when authentication is waiting for SDK response.
didomi:send-authentication-success
didomi:send-authentication-success
is triggered when authentication succeeds.
didomi:send-authentication-error
didomi:send-authentication-error
is triggered when authentication fails.
didomi:verify-otp-code-loading
didomi:verify-otp-code-loading
is triggered when authentication is waiting for SDK response.
didomi:verify-otp-code-success
didomi:verify-otp-code-success
is triggered when authentication succeeds.
didomi:verify-otp-code-error
didomi:verify-otp-code-error
is triggered when authentication fails.
didomi:init-authentication-error
didomi:init-authentication-error
is triggered when the authentication initiate function fails while SDK is loading.
Last updated