-
Notifications
You must be signed in to change notification settings - Fork 312
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
is it possible to flush all batched events at once? #426
Comments
I don't think we currently have a publicly-exposed method to flush everything. The SDK does already attempt to flush every time the page/tab loses visibility: mixpanel-js/src/mixpanel-core.js Lines 308 to 334 in 34b4396
If you just want something that works quickly, calling |
I am using it in an electron app and I want to flush out everything before all windows are closed. |
I know there is
Similarly, I know I can edit the config - but that only effects following events, plus I still want batching.
Use Case: I have a large
batch_flush_interval_ms
interval and want to flush everything before navigation to a new external URL, but I don't want to give up my batching and usesend_immediately
every time I callmixpanel.track
I have tried editing the
flushAfter
property of the events queued inside localStorage with no luck.The text was updated successfully, but these errors were encountered: