Discord.js ~ Is there a problem in the package?

I am making a bot with discord.js, and it’s throwing an error that says:

/rbd/pnpm-volume/41fedeed-3169-4dce-8b93-845f44febacc/node_modules/discord.js/node_modules/@discordjs/rest/dist/index.js:174
  static {
         ^
SyntaxError: Unexpected token '{'
    at wrapSafe (internal/modules/cjs/loader.js:1001:16)
    at Module._compile (internal/modules/cjs/loader.js:1049:27)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
    at Module.load (internal/modules/cjs/loader.js:950:32)
    at Function.Module._load (internal/modules/cjs/loader.js:790:12)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:101:18)
    at Object.<anonymous> (/rbd/pnpm-volume/41fedeed-3169-4dce-8b93-845f44febacc/node_modules/discord.js/src/client/BaseClient.js:4:18)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)

Link to project: Glitch :・゚✧

Hi there @element - can you try updating the Node engine in package.json to “16.x” as I think that may be the requirement for the version of discord.js you’re doing.

No, it still shows the same error.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.