Just starting out with learning javascript.
Currently trying to troubleshoot this basic code:
console.log("Hello World!\n"); // there's a breakpoint here
let million = 1_000_000;
console.log(million);
However, upon hitting the play button in the debug section, I am faced with:
Process exited with code 1
Uncaught SyntaxError SyntaxError: Invalid or unexpected token
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Module._load (internal/modules/cjs/loader.js:585:3)
at Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)
Seems like node.js hasn't yet adopted the "_" notation for numbers. But it's peculiar how the error message resembles something from a faulty C++ build rather than a script issue.
Would love for the output to resemble that of a higher level language, perhaps like python, where the traceback would pinpoint the file and line of the error. Additionally, any idea why the debugger isn't halting at the breakpoint?
P.S.: Clicking on the dropdown arrow in the debug terminal yields
No debugger available, can not send 'variables'
.