#Replit doesn't understand const?!

12 messages · Page 1 of 1 (latest)

quasi wedgeBOT
#

• 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.

gritty crane
#

this has nothing to do with discord.js. that is just a syntax error.

deft hemlock
#

sorry

gritty crane
#

also, don't rely on chatgpt to write code for you especially if you have no idea what it means

deft hemlock
#

?

gritty crane
#

your original message said you asked chatgpt before deleted

deft hemlock
#

ok, so basically i have a chatgpt bot that worked perfectly fine. But for some reason now that i came back it just stopped working, i have no idea why
(replit says -
/home/runner/Nodejs/index.js:2
const { Client, IntentsBitField, GatewayIntentBits, Routes, InteractionWebhook } = require('discord.js');
^^^^^

SyntaxError: Unexpected token 'const' )

#

i made a chatgpt bot

gritty crane
#

#useful-servers

#

even though you might be using discord.js for your bot, the error isn't something we can help with. sorry

deft hemlock
#

i found the problem