From the course: Angular: Creating and Hosting a Full-Stack Site
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Create an endpoint to create listings
From the course: Angular: Creating and Hosting a Full-Stack Site
Create an endpoint to create listings
- [Instructor] Okay. The next route we're going to create, is the route that will allow users to create new listings. And this will be hit when the user fills out the form and hits the create button on the new listing page. So the first thing we have to do here is install a package called UUID. We'll be using this package in our route to generate random, unique IDs for the new listings that users create. So we're going to say NPM install, UUID and hit enter. And just a note about this package, depending on the version of NOJS you're using on your computer, this package may throw a weird error for you when you try and use it on our server. In particular version 13.5, which is the version I showed you that I was using back at the beginning of the course was causing problems for me so I had to switch back to using version 12.18 here. And keep in mind that the latest versions of Node would probably work as well, but just so you…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
Why MySQL?2m 16s
-
(Locked)
Install MySQL and MySQL Workbench3m 19s
-
(Locked)
Set up a MySQL database5m 32s
-
(Locked)
Connect to a MySQL database from Node6m 44s
-
(Locked)
Rewrite the listings endpoints8m 20s
-
(Locked)
Create an endpoint for adding views5m 29s
-
(Locked)
Create an endpoint to get a user listing3m 13s
-
(Locked)
Create an endpoint to create listings6m 13s
-
(Locked)
Create an endpoint to edit listings4m 34s
-
(Locked)
Create an endpoint to delete listings2m 33s
-
-
-
-
-