Package Exports
- twitch-js
- twitch-js/shims/form-data.js
- twitch-js/shims/node-fetch.js
- twitch-js/shims/ws.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (twitch-js) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
TwitchJS
A community-centric, community-supported Twitch JavaScript SDK.
Warning
This branch is under active development; expect breaking changes. Please use v1 instead. If you still choose to use this branch, use version pinning, refer to the diffs, and update accordingly to avoid regressions.
Features
- Aligns with official Twitch IRC documentation
- Forward-compatible, minimally-assertive architecture
- Supports Node environments
- Supports Browsers
- Connect to multiple channels
- Chat commands
- Rate limiter
In progress...
Here are the planned features. If you feel something is missing, create an issue or submit a PR against the next branch.
Getting started
CommonJS
If you are using a module bundler, such Webpack, Browserify, or a in a Node environment:
Add TwitchJS to your project:
npm install --save twitch-js@next
Import TwitchJS
// ES2015 syntax import Twitch from 'twitch-js' // OR ES5 syntax var twitch = require('twitch-js')
UMD
If you are not using a module bundler, precompiled builds are available in the
dist folder:
- Include a script tag in your HTML:
<script src="//unpkg.com/twitch-js@>2.0.0-beta/dist/twitch-js.min.js"></script>
- Consume the library:
<script type="javascript"> window.TwitchJS ... </script>
Contribution guidelines
If you wish to contribute, please see the CONTRIBUTING doc.
Special thanks
Schmoopiie and all the
original contributors of
tmi.js.
License
MIT
TwitchJS is not affiliated, associated, authorized, endorsed by, or in any way officially connected with Twitch, or any of its subsidiaries or its affiliates. The name "Twitch" as well as related names, marks, emblems and images are registered trademarks of Twitch.