1.0.1 • Published 3 years ago

light-commander v1.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

LightCommander

Installation

npm install light-commander

Setup

const lightCommander = require("light-commander");

const { Client, Intents } = require("discord.js");
const client = new Client({ intents: [Intents.FLAGS.GUILDS, Intents.FLAGS.GUILD_MESSAGES] });

client.on("ready", () => {
    new lightCommander.CommandHandler()
    .setCommandsDir(`commands`)
    .setDefaultPrefix(`!`)
    .ignoreBots(true)
    .registerCommands()
})

Creating Commands

const { Command } = require("light-commander");

module.exports = new Command()
.setName("ping")
.setDescription("Ping pong command.")
.setCallback((message, args, client) => {
    message.channel.send(`Pong!`);
});
1.0.1

3 years ago

1.0.2

3 years ago

1.0.0

3 years ago