Question: Install the latest version of NodeJS from nodejs website Run the cmd / terminal command to show your installed version of node Run the cmd

Install the latest version of NodeJS from nodejs website
Run the cmd/terminal command to show your installed version of node
Run the cmd/terminal command to show your installed version of npm
Take a screenshot of the cmd/terminal window showing the result of both commands
Start a new node project
Set the package.json to run test.js when given the test command
Test.js should output some text
Install dayjs to your node project
Locate and explore DayJS documentation to figure out how to display today's date
Update your test.js to display today's date below the text from the last week.
Create a new file called app.js
Update package.json to run app.js on the start command
Install express to the project
Install consign to the project
Set up your folder structure to mimic the book/demo
Libs
Models
Routes
Create the libs/middlewares.js and libs/boot.js similar to the book/demo
Create a route for / that returns JSON including a message of "Welcome to course management" and uses dayjs to return the current date
Create a model called courses with a findAll function to return the JSON course information you submitted for Week 3
Create a route for /courses that returns the response of the findAll function for courses
Use consign to include all the files and folders necessary for the API to function into app.jsStart with the project from the previous week
Install SQLite
Download sqlite-tools-win32-x86-3290000.zip
Create C:/sqlite (or whichever drive you're using)
Extract the .zip to this folder
Install the sequelize and SQLite modules via NPM
Refactor the project to utilize sequelize as seen in the demo/book, including but not limited to:
Creating libs/config.js
Creating db.js
Modifying: libs/boot.js
Update the existing courses model to be a sequelize model
Create a model for students
Set up 1-N relationship for Courses-to-Students (one course will own many students)
In reality this should be an N-N (many to many) relationship, but I'm trying to keep the assignment as close to the book/demo as possible
Final output when running npm start and going to localhost:3000/courses should output { "courses": []} i need help with this I dont know what I am doing wrong

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!