This allows us to receive the result of the dispatch function in trackEvent calls.
Main use case for this is waiting to execute code until the event has been successfully tracked. Our tracking method inside of dispatch() returns a promise that resolves when the event has been successfully tracked.
We can use this to delay execution of events (for example exiting link clicks on critical events) until the event has tracked.
This allows us to receive the result of the dispatch function in trackEvent calls.
Main use case for this is waiting to execute code until the event has been successfully tracked. Our tracking method inside of dispatch() returns a promise that resolves when the event has been successfully tracked.
We can use this to delay execution of events (for example exiting link clicks on critical events) until the event has tracked.