0
class Match {
  JSDOM = jsdom;
  Discord = require("discord.js");
  jsdom = require("jsdom");
  …
}

This is the code I use, and I get the error:

JSDOM = jsdom();
        ^
SyntaxError: Unexpected token =

Why? This should work right? This only happens when I try to run the code on repl.it. When I run it on my computer it works fine.

delta-alph
  • 21
  • 2
  • 6

1 Answers1

0

So for anyone wondering, I found the problem. I was importing the project from GitHub, when I made a new REPL and specified node.js as the language, then imported the files, everything worked as expected.

delta-alph
  • 21
  • 2
  • 6