Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/aelew/discord-bot-template
📝 A lightweight, type-safe Discord.js v14 boilerplate template built with TypeScript and Bun.
https://github.com/aelew/discord-bot-template
boilerplate bot bun discord discord-bot discordjs hacktoberfest javascript t3-env template typescript
Last synced: 2 months ago
JSON representation
📝 A lightweight, type-safe Discord.js v14 boilerplate template built with TypeScript and Bun.
- Host: GitHub
- URL: https://github.com/aelew/discord-bot-template
- Owner: aelew
- License: mit
- Created: 2023-10-02T02:01:11.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-09-21T17:58:56.000Z (3 months ago)
- Last Synced: 2024-10-11T01:57:31.562Z (3 months ago)
- Topics: boilerplate, bot, bun, discord, discord-bot, discordjs, hacktoberfest, javascript, t3-env, template, typescript
- Language: TypeScript
- Homepage:
- Size: 104 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 📝 discord-bot-template
A type-safe Discord.js v14 boilerplate built with [TypeScript](https://www.typescriptlang.org) and [Bun](https://bun.sh).
## Features
- Usage of Discord interactions (application/"slash" commands)
- Type-safe environment variable validation with [t3-env](https://env.t3.gg)
- Example `/ping` and `/purge` commands
- Command and event handlers
- [Biome](https://biomejs.dev) integration## Contributions
Feel free to share your ideas, report issues, and help make discord-bot-template even better!
## Setup
Clone the project
```bash
git clone https://github.com/aelew/discord-bot-template.git
```Go to the project directory
```bash
cd discord-bot-template
```Install dependencies
```bash
bun i
```Set environment variables
```
To run this project, you need to set the required environment variables.
Copy `.env.example` into a new file called `.env` and fill in the values.
```Deploy application commands
```bash
bun run deploy
```Start the bot
```bash
bun start
```## Scripts
```bash
bun start # start the bot
bun lint # run biome linter
bun format # run biome formatter
bun run deploy # deploy commands (run after adding/modifying command data)
```## License
[MIT](https://choosealicense.com/licenses/mit/)