Property 'commands' does not exist even after module augmentation
DJS V14
Hi there, I'm doing
in my index.ts
and I have in /types/common/discord.d.ts however im still getting Property 'commands' does not exist on type 'Client<boolean>'.
when trying to compile.
DJS v14.2.0
NODE v16.10.012 Replies
• What's your exact discord.js
npm list discord.js
and node node -v
version?
• Post the full error stack trace, not just the top part!
• Show your code!
• Explain what exactly your issue is.
• Not a discord.js issue? Check out #useful-servers.yes already done
cannot reproduce
works as expected with exactly that augmentation on 14.2
what es version are you targeting, im doing es2021
2021
im targeting es2021
wtf
thats weird
so after only doing tsc it seems to work, i was running ts-node index.ts before
never used that, no idea
thank you either way
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
changing to file.endsWith(".js"), compiling with tsc and running compiled code
never used ts-node again
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
so i would suggest setting an outDir in your tsconfig to something like dist
so that the compiled files go into a folder called dist
and then after compiling you can run node on the compiled main file