Vanilla JS
1. Insert widget code in the app
You can also integrate the widget using native JavaScript. Add the following code to your project, ensuring that the tads script is loaded beforehand:
Insert the following script into <head> or in the end of <body> in your HTML document:
Insert the following
<div>
where you want to render the ad:
Add the following code to your HTML document to initialize the widget:
2. Add your widget ID
Replace YOUR_WIDGET_ID with the corresponding widget ID you received from your personal account.
3. Set a reward (if needed)
4. Add a script
Before using the native JavaScript widget, ensure that the following script is included in your project:
Last updated