If you have a Single-Page Application (SPA), like React.js, Vue.js, or Angular.js, you can use the following implementation guide based on the React.js example.
1. Create a react app in your desired location using the following command:
npx create-react-app app-name
2. A directory called app-name is created with the following default file:
index.html inside the public directory and add the following script to the <head> tag:
4. Save changes and reload the bundle.js.
Reload the consent framework
In a single page application, most elements are loaded or updated asynchronously. You can use the function below to reload the whole consent framework when needed.