Opt-out
When opt-out is enabled, the SDK stops sending all events.
Configuration at Initialization
import { createInstance, HackleProvider } from "@hackler/react-sdk";
const config = {
optOutTracking: true
};
const hackleClient = createInstance("YOUR_BROWSER_SDK_KEY", config);
ReactDOM.render(
<HackleProvider hackleClient={hackleClient}>
<YourApp />
</HackleProvider>,
document.getElementById('root')
);import { createInstance, HackleProvider } from "@hackler/react-sdk";
const config = {
optOutTracking: true
};
const hackleClient = createInstance("YOUR_BROWSER_SDK_KEY", config);
function MyApp({ Component, pageProps }) {
return (
<HackleProvider hackleClient={hackleClient} supportSSR>
<Component {...pageProps} />
</HackleProvider>
)
}
export default MyAppRuntime Opt-out Control
Persistence Management
The value resets to the value configured in Config on page refresh or revisit.
Last updated