Skip to main content

๐Ÿ”Ž Have a see inside

There is a lot of files inside sources/modules/templates but let's see what it all adds up to.

๐Ÿ‘Š Handlersโ€‹

The purpose of these files is to manage interactions, events, database elements and tasks.

Buttonsโ€‹

buttons โ†’ for your buttons

Channelsโ€‹

channels โ†’ 3 types of files are possible :

  • those ending with create.js will be automatically launched when a channel is created
  • those ending with delete.js will be automatically launched when a channel is deleted
  • those ending with update.js will be automatically launched when a channel is updated

Commandsโ€‹

commands โ†’ for your commands

Membersโ€‹

members โ†’ 3 types of files are possible :

  • those ending with join.js will be automatically launched when a member joins a guild
  • those ending with leave.js will be automatically launched when a member leaves a guild
  • those ending with update.js will be automatically launched when a member is updated on a guild

menus โ†’ for your select menus

Messagesโ€‹

messages โ†’ 3 types of files are possible :

  • those ending with create.js will be automatically launched when a message is created
  • those ending with delete.js will be automatically launched when a message is deleted
  • those ending with update.js will be automatically launched when a message is updated

Modalsโ€‹

modals โ†’ for your modals (forms)

Modelsโ€‹

models โ†’ models are a quick and easy way of creating objects linked to your database; please read the documentation

Presencesโ€‹

presences โ†’ to check presences updates (status & activities of users and bots)

Reactionsโ€‹

reactions โ†’ 2 types of files are possible :

  • those ending with add.js will be automatically launched when a reaction is added to a message
  • those ending with remove.js will be automatically launched when a reaction is removed from a message

Tasksโ€‹

tasks โ†’ define recurring tasks such as an automatic message or checking for updates

โ„น๏ธ Reminderโ€‹

Each folder can contain as many files as necessary, please take care for folders that manage several events (for example: create, update and delete events) to add the extension corresponding to the event in question (channel_create.js, channel_update.js, channel_delete.js)

๐Ÿงฐ Utilsโ€‹

utils โ†’ You will notice that there is a utils folder, which is not automatically imported by the system, it is a totally optional folder which can have any other name (it doesn't matter) in which you save functions, classes or anything else that can be used in your module