Skip to content
/ botdjs-template Public template

A simple discord.js bot template in typescript

License

Notifications You must be signed in to change notification settings

HerIsDia/botdjs-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Discord.js Bot Template

This is a template for creating a Discord.js bot in TypeScript.

Getting Started

To create a new bot project based on this template, you can either:

  • Use this template on GitHub

  • Clone this repository and remove the .git directory:

    git clone https://github.com/herisdia/botdjs-template.git my-bot
    cd my-bot
    rm -rf .git
  • Once you have a copy of the template, you can install the dependencies and start the bot in development mode:

    npm install
    npm run dev

    or

    yarn
    yarn dev

    or

    pnpm install
    pnpm run dev

This will start the bot with nodemon and automatically restart it when you make changes to the code.

Configuration

Copy the .env.example file to .env and fill out the values:

cp .env.example .env

Before you can start the bot, you need to create a .env file with your bot token:

CLIENT_TOKEN=your-token-here
CLIENT_ID=your-client-id-here

Contributing

If you have any suggestions or find a bug, please open an issue or a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.