Meet the Node Console

Hello everybody,
I’ve been stuck on this for a bit, and I’m getting frustrated.
The instructions say,

    1. "Hello World" should be in the console
      However, my code does have console.log("Hello World") inside it.
      Am I putting it into the wrong spot?
      myApp.js:
let express = require('express');
let app = express();
console.log("Hello World");



































 module.exports = app;

package.json:

{
  "name": "fcc-learn-node-with-express",
  "version": "0.1.0",
  "dependencies": {
    "body-parser": "^1.15.2",
    "cookie-parser": "^1.4.3",
    "dotenv": "^16.0.1",
    "express": "^4.14.0",
    "fcc-express-bground": "https://github.com/freeCodeCamp/fcc-express-bground-pkg.git"
  },
  "main": "server.js",
  "scripts": {
    "start": "node server.js"
  }
}

I’m quite confused as it is, so please respond simply and ASAP.

what link are you submitting?

The one you told me to.

the one for this workspace is a new one, so make sure to get the one for this workspace and not use the old one

next, did you save the file and restart the server?

I am on the correct workspace, and I’ll try and save the file and restart the server right now.

It says this on my screen:


Is this normal?
(not complete screen)

yes, you will add the page in a few steps
for now you need to just have the value logged to the console

remember to copy the new link from this workspace too

I did already, and it doesn’t work. What else should I double-check?

This is what it says when I press “I’ve completed this challenge”,


Does this mean something bad?

it means you are not doing the thing asked.

How did you restart the server?

I refreshed the page, but I should’ve used something else, right?

in the terminal, press Ctrl + C to stop the server, then run npm run start

you can also follow this part of the instructions

To implement server auto restarting on file save Node provides the --watch flag you can add to your start script "start": "node --watch server.js" or you can install an npm package like nodemon . We will leave this to you as an exercise.

so you don’t need to stop and start the server all the times doing the following challenges

I already did press Ctrl + C, so I just typed npm run start, and it showed this:


What now? Should I repress the “I’ve completed this challenge button”?

it depends, do you want to check if you pass the challenge?

1 Like

Okay, already figured that out. Thank you for your help!

Sorry if I’ve been an annoyance lately.

1 Like