Compatibility
The Rollerz SDK is designed to work with virtually any web-based game technology. The only hard requirement is a browser environment that can load a <script> tag and serve pages over HTTP/HTTPS.
Languages
| Language | Support | Notes |
|---|---|---|
| JavaScript (ES2022+) | Full | The SDK bundle is a plain IIFE script — no build step required on the game side |
| TypeScript 5.x | Full | Install @rollerz/sdk as a dev dependency for complete type definitions and IntelliSense |
Game code can be written in vanilla JavaScript or TypeScript. The SDK exposes window.RollerzSDK as a global, so no module import is required at runtime.
# Optional: add types for IDE autocomplete
npm install @rollerz/sdk --save-devTechnologies
| Technology | Compatible | Details |
|---|---|---|
| Browser DOM | Required | The SDK uses window, document, postMessage, and creates a hidden <iframe> |
| HTTP / HTTPS | Required | The SDK bridge and API calls require a proper origin — file:// will not work |
| Node.js | Not needed | The SDK runs entirely in the browser; your game does not need a server-side runtime |
| Web Workers | Not supported | The SDK must run on the main thread (it manipulates the DOM) |
WARNING
Your game must be served over HTTP or HTTPS. Opening an HTML file directly from disk (file:// protocol) will fail because the bridge iframe and API calls require a valid origin. Use any local dev server (e.g. npx serve, Vite, webpack-dev-server) during development.
Frameworks
The SDK is framework-agnostic. It attaches to window.RollerzSDK, so it works in any environment that runs in a browser.
| Framework | How to integrate |
|---|---|
| Plain HTML/JS | Add <script> tag directly in <head> |
| React, Vue, Angular, Next.js, etc. | Add <script> tag to the HTML entry file (public/index.html, index.html, src/index.html, or via Next.js <Script> / _document.tsx), then access window.RollerzSDK from components. For Next.js, use client components only. ⚠️ Should work but not yet tested in production — please report any issues. |
TIP
For TypeScript projects using any framework, install @rollerz/sdk as a dev dependency to get type definitions for window.RollerzSDK without needing to declare types manually.
Game Engines
Any web-based game engine that outputs to a browser context is compatible, as long as it allows adding a <script> tag or loading external JavaScript.
| Engine | Compatible | Integration method |
|---|---|---|
| Unity (WebGL) | Coming soon | Native C# bindings via a WebGL plugin are in development — contact us for early access. |
| Phaser, Three.js, Babylon.js, etc. | ⚠️ Should work but not yet tested in production — please report any issues. |
Minimum browser requirements
The SDK targets modern browsers (ES2022). The following are supported:
- Chrome / Edge 94+
- Firefox 93+
- Safari 15.4+
- Any Chromium-based browser (Opera, Brave, etc.)