Skip to content

Supporting navigator.sendBeacon option #13

@dquang-tran

Description

@dquang-tran

Currently, all the POST requests sent from the sdk are done through fetch.

There are situations when this doesn't work great. For instance, if the request is fired on browser's beforeunload event, it will be cancelled before being sent to the server. Being able to send an event at the end of user's browsing session is useful when, say, you want to keep track of user's activity duration the page.

Libraries such as google analytics support the option of sending an event through navigator.sendbeacon, which is specifically made for this use case.

Would you be open to having this option in giap?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions