Giter VIP home page Giter VIP logo

biscuit's Introduction

biscuit

A brand new bleeding edge non bloated Discord library

biscuit

Install (for node18)

npm install @biscuitland/core
yarn add @biscuitland/core

for further reading join our Discord

Most importantly, biscuit is:

  • A wrapper to interface the Discord API
  • A bleeding edge library

Biscuit is primarily 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!
  • Scalable

Example bot (TS/JS)

import { Session } from '@biscuitland/core';
import { GatewayIntents } from '@biscuitland/api-types';

const session = new Session({ token: 'your token', intents: GatewayIntents.Guilds });

const commands = [
    {
        name: 'ping',
        description: 'Replies with pong!'
    }
];

session.events.on('ready', ({ user }) => {
    console.log('Logged in as:', user.tag);
    session.upsertApplicationCommands(commands, 'GUILD_ID');
});

session.events.on('interactionCreate', (interaction) => {
    if (interaction.isCommand()) {
        // your commands go here
        if (interaction.commandName === 'ping') {
            interaction.respondWith({ content: 'pong!' });
        }
    }
});

session.start();

Links

Known issues:

  • node18 is required to run the library, however --experimental-fetch flag should work on node16+
  • redis cache (wip)
  • no optimal way to deliver a webspec bun version to the registry (#50)

biscuit's People

Contributors

dragurimu avatar drylozu avatar fabriziocoder avatar freeaoi avatar marcrock22 avatar nicolito128 avatar paperdave avatar santi24yt avatar socram03 avatar teaishealthy avatar yuzudev avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.