How do I add prefix commands to my bot mostly working on slash commands?
Hey, so I was trying to add prefix commands to my slash commands based bot by following a TUTORIAL, which led to me just running errors at this point.. for this, I created
prefix.js
under ./src/handlers/loaders
, another prefix.js
under ./src/events/client
, and a prefix command ping.js
under ./src/Commands/tools
and now I'm facing errors when running it..
prefix.js
under ./src/handlers/loaders
prefix.js
under ./src/events/client
ping.js
under ./src/Commands/tools
AND NOW HERE'S THE ERROR I'M FACING:16 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!show event.js
event.js
under ./src/handlers/loaders
What next?you export an object, and Object.bind() isnβt a function
What's the solution then?
event.js
was working with no errors tho before I added prefix commandlog
event
then and show what the output is before you have the errorHow to do that?π
console.log
In which line?
preferably 20
Sorry if I'm irritating, I'm just new.
Can you add it and send me the code if you don't mind?π
no
Uhk
did you write this code?
Umm no