Get Started
Custom Rendering Javascript SDK
A Javascript SDK that lets you handle the rendering yourself
We recommend using the Javascript SDK, however if you need more control over ad rendering and tracking, you can use this version.
This Javascript SDK provides more control over ad rendering and tracking. It uses the same core functionality as the Javascript SDK but gives you responsibility for DOM manipulation and view tracking.
1. Import the SDK
A detailed overview of the SDK can be found in the SDK Reference.
2. Setup Parameters
Use the same parameters as the Javascript SDK, but omit the element
property since you’ll handle rendering yourself
3. Handle Rendering and Tracking to display the ad
Create a container element and use the callbacks to manage content and tracking
Important Notes
- You are responsible for rendering the markdown content into HTML
- The
markAdAsViewed
function should be called only when the ad is fully visible in the viewport - Consider debouncing the intersection observer callback if needed