Ready listener doesn't run

Hey, my ready listener doesn't want to run and I don't know why. I'm kind of new to this framework and I copied the most things from the guide. I've attached some screenshots with the relevant code and output.
No description
No description
No description
No description
Solution:
inside package.json, there should be a property called main. make sure its set to dist/index.js because sapphire uses that to determine where your commands/listeners/etc are located
Jump to solution
4 Replies
Solution
Seren_Modz 21
Seren_Modz 212mo ago
inside package.json, there should be a property called main. make sure its set to dist/index.js because sapphire uses that to determine where your commands/listeners/etc are located
Seren_Modz 21
Seren_Modz 212mo ago
the warning for such can also be found here: https://www.sapphirejs.dev/docs/Guide/getting-started/getting-started-with-sapphire (in the first red "danger" box)
Sapphire Framework
Getting started with Sapphire | Sapphire
To install Sapphire, you need to install both discord.js and
Leon
LeonOP2mo ago
Ah, thanks. 👍 I thought I need to set it to src/index.ts because I'm using typescript.
Seren_Modz 21
Seren_Modz 212mo ago
you can think of it as being what you pass to node, to start the bot. a perk of it is that it allows you to run node . instead of having to pass the file yourself. node will convert the dot into what is inside that main property.

Did you find this page helpful?