Basic Node and Express - Meet the Node console

My solution is not passing.
Written in the server.js file of my glitch app I have the following…

console.log(‘Hello World’);

The glitch app editor url: Glitch :・゚✧

Any help would be greatly appreciated. Thanks.

1 Like

You’re getting a No 'Access-Control-Allow-Origin' header is present on the requested resource error, I’m getting the same one trying to access glitch to start the APIs and Microservices. You can see this if you open the browser console when you try and submit the URL for the challenge. I’ve dealt with it before but I don’t remember how to fix it. I think I’ll crack that after I finish D3 and Responsive Web Design.

The boilerplate which I use (the one mentioned on the instructions) has a myApp.js where is supposed to write the solutions, and not on the server.js, there says

/ ******************************************************

  • PLEASE DO NOT EDIT THIS FILE
  • the verification process may break
  • ***************************************************/
4 Likes

UPDATE:
When I run the solution the error I get back is below…

// running test
Not found
// tests completed

Hi zdflower,
There was no mention of a boiler plate in the instructions I have. However, I just used the boilerplate for the link you sent across and the solution passed. Thank you.

2 Likes

You’re wellcome! This are the instructions I mentioned https://learn.freecodecamp.org/apis-and-microservices/basic-node-and-express

“Hello World” is not in the server console.
How to solve this error?

Please help.

“Hello World” is not in the server console.

How to solve this error?

Please help asap.

1 Like

Post the link to the project, or tell more about what you did. I don’t know what the problem could be. I used the boilerplate from here: https://glitch.com/#!/import/github/freeCodeCamp/boilerplate-express/ and had no problems.

me too please help :slight_smile:

Hi, what’s the problem you need help with?

I’ve tested the original boilerpoint that FCC suggested and the one that zdflower also recommended. While zdflower’s boilerplate was passing the solution, when I go to the page it says ‘not found’ on the app landing page.

Not giving up on the former build, I’ve finally figured out how to fix the original boilerplate issue by shortening the title of the app . My original title consisted of 29 characters and I shortened it to 21 characters and tried passing it again and finally solved my issue.

1 Like

Im having the same issues as above. Its not passing. I assume that you just have to write console.log(’“Hello World”’); under the header in myApp.js but ive used both boiler plates stated above and i keep getting

// running test
“Hello World” is not in the server console
// tests completed

Here is a link to my glitch boiler plate.

I was having problems with this challenge as well but was able to pass the tests after reading this thread.

While I was writing down my solution I found that I still could not identify the problem.
The first time I visited the link to Glitch(https://glitch.com/#!/import/github/freeCodeCamp/boilerplate-express/) from the introduction page(https://learn.freecodecamp.org/apis-and-microservices/basic-node-and-express), I landed on a project page that did not have a myApp.js file. After I found this thread and visited the link provided by @zdflower I landed on a project page that had a myApp.js file. I checked the URL’s for both links and they are the same. Maybe there is a problem with Glitch?

Additionally, I signed up for a Glitch account after visiting the link to the project the first time and had to visit it a second time to start coding. Maybe there was a problem with something cache/cookie related? I’m not sure what the problem is, but if the Glitch link you follow doesn’t have a myApp.js file, try another browser or clearing your cache and let us know if you’re still having an issue.

2 Likes

if you had troubles with this issue, you can try to write the code in myApp.js as the image showed, I used this way to pass the test. Good luck~~~

4 Likes

Guys, I belive I know the issue - the most probably you are trying to code within the previous project - where you had been working during the previous section “Introduction to Managing Packages” or any else. You must follow the link provided by this manual https://learn.freecodecamp.org/apis-and-microservices/basic-node-and-express and that open you the proper one with “myApp.js” file inside. I had the same issue until I opened a new project in this block.

8 Likes

I have the same issue, (’“Hello World” is not in the server console’) even though I have written the exact same code in the exact same spot as ccrubby214. There seems to be no way to save the code in Glitch, so I can’t be confident that the code I’ve written is the code being tested. I haven’t done any previous projects in Glitch so that won’t have anything to do with it. I also tried ‘remixing’ the project to be sure that I am coding in my own user account and still having issues.

Thanks Milyaniko, I had the same issue and couldnt figure out what was wrong. Yeah, was working on the wrong boilerplate.

On the left side of the PAGE:
Next to your profile image is a button called ‘Share’
click open and Copy the link under APP

6 Likes

This is the solution that worked for me :slight_smile: Thanks Alex!