Skip to content

Instantly share code, notes, and snippets.

@williscool
Last active August 29, 2015 14:04
Show Gist options
  • Save williscool/94e4fa1ffa9f7559e800 to your computer and use it in GitHub Desktop.
Save williscool/94e4fa1ffa9f7559e800 to your computer and use it in GitHub Desktop.
Title
  1. install node
  2. install npm if you have to and npm init
  3. npm install express --global --save
  • global makes the files go to a global dir on your comp instead of in the repo
  • save adds it as a dep to your package.json (the functional equivalent of a Gemfile for node.js apps)
  1. have an express app that will just serve assets
  • it serves stuff in the public dir that is where out app will be
  • index.html is a convention that lets the server know that if a person hits the root of a url server this html
  1. add bower (because it will get alot of assets and stuff for us)
  • npm install bower --global
  1. bower install angular in public dir
  • bower init
  • bower install angular --save
  • there is no magic here. all it does is create a download angular and put it in the bower components file
  • the --save part of the command persits it to our bower.json which keeps track of all the external assets our app uses
  1. have an index.html add angular to it
  2. have an app.js

Written with StackEdit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment