1.0.1 • Published 2 years ago
twitch-channel v1.0.1
twitch-channel
A small library to listen to various events that can happen on a twitch channel (chat messages, raids, follows, subscriptions…)
This library acts as a layer on top of various twitch APIs (currently: IRC and EventSub) so you only have to interact with a single EventEmitter that emits uniform events.
The event objects are kept simple and without surprises.
Full documentation: https://thomaslule.github.io/twitch-channel/classes/TwitchChannel.html
import { TwitchChannel } from "twitch-channel";
const channel = new TwitchChannel({
channel: "your_channel",
clientId: "your_app_id",
clientSecret: "your_app_secret",
});
channel.on("sub-gift-received", ({ gifterName, recipientName }) => {
console.log(`${gifterName} just subgifted ${recipientName}`);
});
channel.on("log", ({ level, message, error }) => {
console.log(`[${level}] ${message}`, error);
});
await channel.connect();
1.0.1
2 years ago
1.0.0
2 years ago
1.0.0-next.1
2 years ago
1.0.0-next.2
2 years ago
1.0.0-next.3
2 years ago
1.0.0-next.4
2 years ago
0.4.6
3 years ago
0.4.5
4 years ago
0.4.4
4 years ago
0.4.3
4 years ago
0.4.2
4 years ago
0.4.1
5 years ago
0.4.0
5 years ago
0.3.2
5 years ago
0.3.1
5 years ago
0.3.0
5 years ago
0.2.5
5 years ago
0.2.4
5 years ago
0.2.3
5 years ago
0.2.2
5 years ago
0.2.1
5 years ago
0.2.0
6 years ago
0.1.3
6 years ago
0.1.2
6 years ago
0.1.1
6 years ago
0.1.0
6 years ago