Get Started
Installation
Add @streamerbot/client to your project
Browser
For usage in browser contexts, such as basic static HTML and JS projects.
Add the following <script>
tag within the <head>
of your HTML page.
<script type="text/javascript" src="https://unpkg.com/@streamerbot/client/dist/streamerbot-client.js"></script>
The StreamerbotClient
constructor will become available on the global window
object.
<!DOCTYPE html>
<html>
<head>
<title>Streamer.bot Client</title>
<link rel="stylesheet" href="style.css">
<script type="text/javascript" src="https://unpkg.com/@streamerbot/client/dist/streamerbot-client.js"></script>
</head>
<body>
<script type="text/javascript">
const client = new StreamerbotClient();
</script>
</body>
</html>
NodeJS & TypeScript
Add @streamerbot/client
with your favorite package manager:
pnpm install @streamerbot/client
Import Streamer.bot client in your .js
or .ts
:
import { StreamerbotClient } from '@streamerbot/client';
Module
You can also directly import the module from Skypack if you are using the <script type="module">
syntax:
<script type="module" src="my-module.js"></script>