1

Hi my issue is that in my visual studio code, my code runner extension doesn't provide any output. I've looked at a bunch of tutorials and have done everything, research, download node.js,and saves the file as a javascript file and verify paths.

I entered " console.log("Hello") Its prints this out [Running] node "c:\Users\NAME\Untitled-1.js [Done] exited with code=0 in 0.202 seconds

And nothing enter image description here

Please help idk what I'm doing wrong

Adarsh Madrecha
  • 6,364
  • 11
  • 69
  • 117
Richard NY A
  • 11
  • 1
  • 2
  • i've done every single things these people wrote as answers and it didn't change a thing. Were you able to do it? – danistor_m Aug 25 '22 at 14:29

3 Answers3

3

Looks like you haven't saved the file.

Try saving the file and then run with Code Runner.

Tip: You can enable Save before Run settings so that it gets saved every time before running the file.

File -> Preferences -> Extensions -> Run Code Configuration -> Save File Before Run

enter image description here

Shri Hari L
  • 4,551
  • 2
  • 6
  • 18
0

I recommend you to run node -v and npm -v in command prompt window to see if you have them installed

the output must be like this

C:\Users\Anonymous>node -v
v16.14.0

C:\Users\Anonymous>npm -v
8.3.1

and if there is a problem it might be from your paths ("Edit system environment variables" in windows search) or you haven't installed npm or node.

Rocky
  • 117
  • 1
  • 1
  • 9
0

in my case solution was to uncheck "Show Execution Message" check box in Run Code configuration.

setting

1

result

2

vimuth
  • 5,064
  • 33
  • 79
  • 116
vst
  • 1
  • 1