2021-12-25 17:10:17 +00:00
2021-12-24 23:06:01 +00:00
2021-08-12 12:00:07 +01:00
2021-07-12 17:13:40 +01:00
2021-04-19 15:37:19 +00:00
2021-12-23 19:34:17 +00:00
2021-12-24 23:04:38 +00:00

revolt.js

revolt.js revolt-api

revolt.js is a direct implementation of the entire Revolt API and provides a way to authenticate and start communicating with Revolt servers. This is an ESM library!

Example Usage

import { Client } from "revolt.js";

let client = new Client();

client.on("ready", async () =>
    console.info(`Logged in as ${client.user!.username}!`),
);

client.on("message", async (message) => {
    if (message.content === "sus") {
        message.channel!.sendMessage("sus!");
    }
});

client.loginBot("..");

If you are using Node, you must specify --experimental-specifier-resolution=node.

For example, node --experimental-specifier-resolution=node index.js.

MobX

MobX is used behind the scenes so you can subscribe to any change as you normally would, e.g. with mobx-react(-lite) or mobx's utility functions.

import { autorun } from 'mobx';

[..]

client.once('ready', () => {
    autorun(() => {
        console.log(`Current username is ${client.user!.username}!`);
    });
});
S
Description
Typescript library for interacting with Stoat
Readme MIT 12 MiB
Latest
2026-01-16 13:28:35 -05:00
Languages
TypeScript 99.4%
JavaScript 0.5%