npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

slate-irc-twitch

v2.0.2

Published

Twitch commands plugin for slate-irc.

Downloads

47

Readme

slate-irc-twitch

Twitch commands plugin for slate-irc.

NPM

Usage

const irc = require('slate-irc')
const twitch = require('slate-irc-twitch')

const client = irc(stream)
client.use(twitch({ init: true
                  , tags: false }))

client.ban('#my_stream', 'annoying_user')

API

twitch(opts={})

Returns a plugin for .use() with slate-irc. Options:

  • init: Whether to send the twitchs-related CAP messages and the TWITCHCLIENT message automatically. If true, you shouldn't call twitchinit() yourself. Defaults to false.
  • tags: Whether to ask for tags in IRC messages. (Sends CAP REQ :twitch.tv/tags.) Defaults to false.
  • membership: Whether to ask for JOIN/LEAVE messages when users join or leave chat. (Sends CAP REQ :twitch.tv/membership.) Defaults to true.

client.twitchinit()

Initialises Twitch-specific IRC functionality by sending a capability request and a TWITCHCLIENT message.

client.twitchcap()

Sends a capability request. Asks for twitch.tv/commands normally, and for twitch.tv/commands twitch.tv/tags if the tags option is enabled.

client.twitchclient(version=4)

Sends a TWITCHCLIENT message.

client.mods(channel[, cb])

Gets the list of moderators on a channel. The callback takes (error, mods), Node-style, where mods is an array of moderator usernames.

client.on('mods', cb)

Called when a moderators message is received, usually after a .mods() call.

client.ban(channel, username)

Bans a user from the given channel.

client.unban(channel, username)

Unbans a user from the given channel.

client.clear(channel)

Clears the chat.

client.color(channel, color)

Sets your user colour. color is a hex sextet, eg. "#FF00FF". Non-turbo users can only choose from a specific set of colours.

client.commercial(duration=30)

Starts a commercial on the stream. Duration can be 30, 60, 90, 120, 150 or 180.

client.host(channel, target)

Start hosting an other channel.

client.unhost(channel)

Stop hosting the other channel.

client.mod(channel, user)

Give moderator status to a user.

client.unmod(channel, user)

Remove moderator status from a user.

client.r9kbeta(channel)

Enable R9K anti-spam in the chat.

client.r9kbetaoff(channel)

Disable R9K anti-spam in the chat.

client.slow(channel)

Enable slow mode.

client.slowoff(channel)

Disable slow mode.

client.subscribers(channel)

Enable subscriber-only mode.

client.subscribersoff(channel)

Disable subscriber-only mode.

client.timeout(channel, user, duration = 600)

Times out a user for duration seconds. This will stop them from chatting for the given amount of seconds; 10 minutes by default.

Licence

MIT