Node Homework

This weekend your optional homework is to do the following:

  1. Create a full stack RESTful API in Node (from scratch).
  2. Use MongoDB to server a collection through an API route.
  3. The API should be mapped to localhost:3000/api.
  4. You should also render a view at localhost:3000/. This view should contain an Ajax Call to the API to return all of your items.
  5. Use that Ajax call to render your API's data on your page.
  6. An example of making an Ajax call is in this Gitbook.

This should be submitted by pull request if you do it. This practice is going to lead into using Backbone.js next week! By knowing how we can make Ajax calls to our API on our server, we'll be able to do the same with Backbone.js (but easier).

results matching ""

    No results matching ""