Basic Usage
Command handler
Setup
//index.js
const SHClient = require('shandler');
const Discord = require('discord.js');
const client = new Discord.Client();
const options = {
commandsDir: 'commands', // commands folder path (required)
showLogs: 'extra', // "extra"|"normal"|null (default: "extra")
wrapper: false, // defaults to false
cLogs: true, // logs most of the resolved promises
autoDelete: true, // Automatically syncs the global application commands
autoRegister: true, // Automatically register commands
exclude: ['file'] // Exclude a file from the command directory. Make sure you only put the file name.
}
const handler = new SHClient(client, options);Wrapper
Last updated
Was this helpful?