I just intalled node.js on my Mac M3. When I open the VS code terminal and I try to execute node command like this one ‘ node Pet.js’ it is showing me this error…
node Pet.js
node Pet.js
^^^
Uncaught SyntaxError: Unexpected identifier ‘Pet’
I’m currently running this version of node Welcome to Node.js v20.13.1.
I tried to run the Pet.js.
The version of node.js I’m currantly running is Node.js v20.13.1.
Thank you!
Vasil Ginin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.