Svelte Guide
Install
The Svelte SDK is available via npm:
Setup
Import Resubscribe.
Add the component to your tree. It will not render anything until you trigger it.
When you would like to open up Resubscribe, call openWithConsent, replacing the placeholder values with your own values.
The value of userId
MUST be unique. If you do not have a unique user id at the point you want to make this call, we recommend generating a random value prefixed with 'anonymous-' for every user
Configuration
You can pass the following parameters into openWithConsent.
Headless
Resubscribe additionally supports a headless mode if you would like more control over the consent modal. This is not recommended.
Last updated