Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Week 1 prep for Node.JS #616

Open
MarcusZagorski opened this issue Mar 11, 2024 · 0 comments
Open

Week 1 prep for Node.JS #616

MarcusZagorski opened this issue Mar 11, 2024 · 0 comments
Labels
probably obsolete it seems likely this can be closed but not certain
Milestone

Comments

@MarcusZagorski
Copy link

MarcusZagorski commented Mar 11, 2024

Describe the bug

In the Building the server of Node.JS week 1 prep, I noticed that when you complete step 1 create a server.js file, it should instead be create a server.mjs file. Reason being is that in step 2, your told to import the express library. This will work, but only if you add type: "module" to your package.json file, which is not stated to do so in the prep. This causes running the command node server.js in the terminal, to produce an error. (Which I'm not going to add because its a bit long).

How could this be fixed?

Option 1 steps:

  1. Keep the "create a server.js file"
  2. Tell people they need to add type: "module" to the bottom of there package.json file
  3. Explain why they need to do this maybe?

Option 2 steps:

  1. Change "create a server.js file" to instead say "create a server.mjs file"
  2. Change step 5 "Switch the server on!" to say "node server.mjs" instead of "node server.js"

Link to content
(https://curriculum.codeyourfuture.io/servers/sprints/1/prep/#building-the-server)

@SallyMcGrath SallyMcGrath added this to the SDC 2: Jobs milestone Jun 4, 2024
@SallyMcGrath SallyMcGrath added the probably obsolete it seems likely this can be closed but not certain label Sep 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
probably obsolete it seems likely this can be closed but not certain
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants