diff --git a/.gitignore b/.gitignore index 7bf6eb1..eeca794 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ bower_components node_modules +npm-debug.log diff --git a/README.md b/README.md deleted file mode 100644 index e982621..0000000 --- a/README.md +++ /dev/null @@ -1,70 +0,0 @@ -# ajax-autocomplete -Search for strings, parse response and add to search input as an autocomplete dropdown list. - -# 1 - get code - -Clone this repo by running the following from a command line. Type everything -except the `$` character at the start of the line -```bash -$ git clone https://github.com/coder-forge/ajax-autocomplete -$ cd ajax-autocomplete -``` - -# 2 - Config files - -In order to keep things clean, all our config files will go into the root -directory of our project. This also means that any developer looking at our app -will instantly know that we are using npm (because of `package.json` file) and -bower (because of `bower.json` & `.bowerrc` files). - -NPM is installed by node by default. It reads the package.json file and installs -our node packages for us. -Bower is installed by node using `npm install -g bower` and manages our front -end packages, ie jquery and bootstrap. - -```bash -. -├── .bowerrc // define where bower will install client packages -├── .gitignore // stuff we want git to the repo -├── bower.json // main bower config file -├── package.json // main npm config file -└── README.md // instructions for both users and developers -``` - -# 3 - important files & directories - -The code that will run our server goes into `app/`. - -```bash -├── app // holds all our code -│   ├── app.js // our main application -│   ├── public // the front end root -│   │   └── sample.json // json endpoint. Get http://localhost:3000/sample.json -│   └── views // view files -│   └── index.jade // jade compiles/turns these into html -``` - -# 4 - Run server - -Run: -```bash -$ npm install -$ npm start -``` - -The server is accessible from [http://localhost:3000](http://localhost:3000) - -The first command will run the `scripts.start` field in the [package.json, in this case calling `nodemon ./app/app.js` -file](https://github.com/coder-forge/ajax-autocomplete/blob/l1-setup-quick-sandbox/package.json#L6). - -```json -{ - "name": "ajax-autocomplete", - "version": "0.0.1", - "private": false, - "scripts": { - "start": "nodemon ./app/app.js", - "postinstall": "bower install" - } - ... -```