Skip to content

notspammail/horizon.js

Repository files navigation

horizon.js

Summary

A discord.js command & event handler.

Quickstart

npm install horizon.js
pnpm add horizon.js
yarn add horizon.js

index.js

// You can use CommonJS or ES6 modules.
const { Handler } = require('horizon.js');
const { Client } = require('discord.js');

const client = new Client({
  // ...
});

new Handler(client, {
  commands: {
    app: {
      directory: path.join(__dirname, 'commands', 'app')
    }
  },
  events: {
    directory: path.join(__dirname, 'events')
  }
});

client.login('TOKEN');