2022-07-12 02:29:37 -05:00
2022-07-12 01:56:48 +00:00
2022-07-12 02:35:32 -04:00
2022-07-12 02:04:23 -05:00
2022-07-11 04:25:23 -05:00
2022-07-12 02:29:37 -05:00
2022-07-04 12:35:17 -05:00
2022-06-19 19:43:35 +00:00
2022-07-10 21:49:36 -05:00
2022-07-03 16:19:09 -05:00

biscuit

A brand new bleeding edge non bloated Discord library

Install (node18)

npm install @oasisjs/biscuit

or via cdn

The biscuit Discord library is built ontop of Discordeno and webspec APIs, we aim to provide portability.

Most importantly, biscuit is:

  • A modular Discordeno fork
  • A framework to build Discord bots
  • A bleeding edge API to contact Discord

Biscuit is primarly inspired by Discord.js and Discordeno but it does not include a cache layer by default, we believe that you should not make software that does things it is not supposed to do.

Why biscuit?:

  • Minimal, non feature-rich!
  • Crossplatform
  • Consistent
  • Performant

Example bot (TS/JS)

import { GatewayIntents, Session } from "biscuit";

const token = "your token goes here";

const intents = GatewayIntents.MessageContent | GatewayIntents.Guilds | GatewayIntents.GuildMessages; 
const session = new Session({ token, intents });

session.on("ready", ({ user }) => {
    console.log("Logged in as:", user.username);
});

session.on("messageCreate", (message) => {
    if (message.content.startsWith("!ping")) {
        message.reply({ content: "pong!" });
    }
});

session.start();

Mininal style guide

  • 4 spaces, no tabs
  • Semi-colons are mandatory
  • Run deno fmt
  • Avoid circular dependencies

Contrib guide

  • Install Deno extension here
  • Run deno check to make sure the library works
  • Avoid sharing state between classes

Compatibility

bun

since bun is unestable I highly recommend running biscuit on node!

  • We got the library running on EndeavourOS but it spams the ready event multiple times
  • We got the library running on Arch/Artix Linux but breaks when sending fetch requests
  • We got the library running on WSL

node

  • all DNT shims work properly
  • a Node version is will to be available soon
Description
the black magic Discord framework 🧙‍♂️
Readme MIT 5.9 MiB
Languages
TypeScript 99.9%