Our next step is to create some method of logging in together with saving what is in our shopping cart. We are not going to create a full fledged web shop, so for the sake of learning, we will manually insert two users into the database, so we can log in and remember what is in each of their shopping carts. Before we can save anything to MongoDB, we must first create a login page for our website. Create a view and name it login.ejs. The contents are pretty much the same as that on other pages. Same stylesheets, scripts, and footer. The part that is different goes in container div. I am using a form element so Angular does the required validation for us. Other than that, it is not much different from doing a regular AJAX POST later on:
[...]
<script src="..\scripts\bundles\login.bundle.js"></script>
<!-- endbuild -->
</head...