Skip to content
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

Document keepalive in quickstart example #1203

Open
cseas opened this issue Dec 18, 2024 · 1 comment
Open

Document keepalive in quickstart example #1203

cseas opened this issue Dec 18, 2024 · 1 comment

Comments

@cseas
Copy link

cseas commented Dec 18, 2024

I've used the JavaScript quickstart document to setup Segment using the snippet.

How do I setup keepalive in the same to make sure Segment requests complete before a redirection happens?

The docs just mention a link to this comment which doesn't clearly explain how keepalive is supposed to be used when Segment is installed via snippet.

@silesky
Copy link
Contributor

silesky commented Dec 18, 2024

@cseas Thanks for the feedback! There are two slightly-different APIs (not my decision).

The snippet is:

analytics.load('<MY_WRITEKEY>',  // first argument is string, not object
      {
        integrations: {
          'Segment.io': {
            deliveryStrategy: {
              config: {
                keepalive: true,
              },
            },
          },
        },
      }
    )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants