Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/connor4312/uoftdev-web-bootcamp
https://github.com/connor4312/uoftdev-web-bootcamp
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/connor4312/uoftdev-web-bootcamp
- Owner: connor4312
- Created: 2014-09-08T15:30:33.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-09-09T02:23:55.000Z (over 10 years ago)
- Last Synced: 2024-10-25T22:14:56.572Z (about 2 months ago)
- Language: JavaScript
- Size: 125 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# uoftdev-web-bootcamp
In order to build and run this, ensure you have [Node.js (with npm)](http://nodejs.org/download/) installed on your system.
This project uses a basic Express web server and a Gulp build environment. Note that much of the minification I'd normally put in Gulp has removed -- this is based on [gulp-breakout](https://github.com/connor4312/gulp-breakout). No reason to eat 200 mb of disk space for stuff that isn't needed :)
Not a ton of work was put into the design. Sorry. If you want to see nice design, check out [this site](http://mcprohosting.com/).
### Usage:
1. cd into the project folder
2. Only once: run `npm install && bower install && gulp`.
3. Copy `config.example.js` to `config.js`, and change details as desired.
3. Run `npm start` to boot the server. By default it is accessible on http://localhost:3000.### API
Favorites are persisted in memory, per server instance. When the server is restarted, favorites are lost. Endpoints:
* `GET /search?query=cats` Returns a random image object for the query, containing data like `{favorite: boolean, id: integer, url: string, query: string}`.
* `GET /favorites` Returns a list of favorited image objects.
* `POST /favorites` Add a favorite. Expects the `id` and `query` of the image to be given in the POST body or as GET params.
* `DELETE /favorites` Removes a favorite. Expects the `id` and `query` of the image to be given in the POST body or as GET params.