Sapphire not getting my commands
Every time i make a command it seems that sapphire doesnt care about them, i put my commands in the commands directory, I am using
tsx
for my runner (tsx uses esbuild)Solution:Jump to solution
Every time i make a command it seems that sapphire doesnt care about them, i put my commands in the commands directory, I am using
tsx
for my runner (tsx uses esbuild)20 Replies
Here is some of my code
My help.ts while in the making
when I change help.ts
tsx
doesnt care since its not being used or imported anywhere which tells me sapphire is not picking up my commmandsread the big red block at the top of the guide: https://www.sapphirejs.dev/docs/Guide/getting-started/getting-started-with-sapphire
More than we also dont support tsx. You can instead just use
tsup
package to compile and it has a --onSuccess
flag through which you can set pnpm run start
to call node dist/index.js
Sapphire Framework
Getting started with Sapphire | Sapphire
To install Sapphire, you need to install both discord.js and
yeah i just switched to tsup after I posted this when I looked at the dragonite bot
it has started to work
thanks
hey sorry, accidently marked solution right before I wanted to ask something else, although nvm as it still doesnt register my commands, I suppose is it because I need guildid's and how do I make guild id commands
you dont need guildId, without they are registered globally
how long does it take to register
since it hasnt registered
instant
weird
it hasnt registered anything
check all your code, add logging, etc
there are many examples available through running bots
Discord bots that use @sapphire/framework v4
- Official Bot Examples ᴱ ᴰ ᴶˢ
- Archangel ᴱ ᴰ
- Dragonite ᴱ ᴰ
- Radon ᴱ ᴬ
Discord bots that use @sapphire/framework v3
- Arima ᴱ
- Nino ᴱ ᴰ
- Operator ᴱ ᴬ ᴰ
- Sapphire Application Commands Examples ᴱ
- Spectera ᴬ
Discord bots that use @sapphire/framework v2
- Materia ᴱ
- RTByte ᴱ ᴬ
- Skyra ᴬ ᴰ
- YliasDiscordBot ᴬ
ᴱ: Uses ESM (if not specified then uses CJS)
ᴬ: Advanced bot (if not specified it is a simple bot, or not graded)
ᴰ: Uses Docker in production
ᴶˢ: Written in JavaScript. If not specified then the bot is written in TypeScript.
and also check the guide, as it explains a lot
aye its radon
my friends bot
ok still been trying everything and nothings working
cant help without you providing info buddy
When asking for help, make sure to provide as much detail as possible. What have you tried so far? Do you have stacktraces that you can show us? What are you trying to achieve? Try to answer these questions and others, so we do not have to ask for them afterwards.
❯ For a good guide on how to ask questions, see the instructions that StackOverflow gives. You should try to always follow these guidelines. ❯ For an excellent video that shows how not to ask technical questions is this, watch this YouTube video by LiveOverflow. ❯ Asking technical questions (Clarkson) ❯ How to ask questions the smart way (Raymond)
can I give you the source code
im uploading it to github rn
here you go https://github.com/yuzofff/eggbot
GitHub
GitHub - yuzofff/eggbot
Contribute to yuzofff/eggbot development by creating an account on GitHub.
I said read the big red block, you didnt do that
OHHH
im so stupid
IT WORKED
Omg thank
The question itself is marked as solution
Mark this message as the solution @yusof
already did