Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ardelan869/discord-js-boilerplate
A boilerplate for a Discord-Bot written in TypeScript using discord.js@v14
https://github.com/ardelan869/discord-js-boilerplate
discord discord-bot discord-bot-template discord-js discord-js-v14 discordjs ts typescript
Last synced: 2 months ago
JSON representation
A boilerplate for a Discord-Bot written in TypeScript using discord.js@v14
- Host: GitHub
- URL: https://github.com/ardelan869/discord-js-boilerplate
- Owner: ardelan869
- Created: 2024-07-21T06:10:52.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-09-21T14:14:14.000Z (3 months ago)
- Last Synced: 2024-09-28T08:41:32.134Z (3 months ago)
- Topics: discord, discord-bot, discord-bot-template, discord-js, discord-js-v14, discordjs, ts, typescript
- Language: TypeScript
- Homepage:
- Size: 43.9 KB
- Stars: 5
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# discord-js-boilerplate
A boilerplate for a Discord bot written in TypeScript. The boilerplate is inspired by and based on a YouTube tutorial (which I can't find anymore).
# Explanations
## File Routing
> [!NOTE]
> Each directory contains an example file.\
> Files including `.dev.` (a.e. `example.dev.ts`) are only included in development mode.\
> The files in the listed directories are automatically imported and registered when the bot starts up.\- `commands/`: The commands folder.
- `events/`: The events folder.
- `selections/`: The selections folder.
- `buttons/`: The buttons folder.## Globals
> [!NOTE]
> The globals can also be accessed without `global.`- `global.dev` (boolean): Whether the bot is in development mode or not.
- `global.client` (Client): The Discord.js Client instance.
- `global.env` (Env): The environment variables.
- `global.config` (Config): Your config.json file, including type-safety.# Todo
- [x] Add ESLint & Prettier
- [x] Make env variables type-safe
- [x] Add multiple-guild support
- [ ] Add runtime editing/unregistering to commands & events
- [ ] Improve buttons and selections.
- [ ] Add temporary components
- [ ] Add awaitable functions (maybe)
- [ ] Add a logger
- [ ] Add utilities (date formatting, etc.)
- [ ] Add stuff for User Applications
- [ ] Add an ORM, like Drizzle, or Prisma (maybe)