A simple web store, with a range of windsurfing products dynamically loaded from a database, a user accounts system, a shopping-cart stored in cookies, a search feature, and a design-your-own-sail app.
Originally written for the University of Bristol's COMS32500 Web Technologies unit.
Deployed on Heroku:
WindsurfShop
Simply clone the repo, and install dependencies:
git clone http://github.com/lukestorry/windsurf-shop
cd windsurf-shop
npm install
npm start
runs the server with node
, head to http://localhost:3000/
to see it.
npm run devstart
same as above, but with nodemon
, so the server restarts upon file changes.
npm run deploy
deploys to Heroku, if the remote app has been set up.
npm run reset-database
removes the database, and instantiates new empty tables.
npm run update-products
overwrites the products table in the database with the contents of the products.csv file.
npm run check-database
outputs the schema and names of items of both the user and products table, to check functionality.
Uses a Node.js Express Server to deliver XHTML rendered by the Pug templating engine, with adapted Bootstrap styling.
Bcrypt and Passport handles authentication and authorization, with CSRF protection from csurf
Products and users are stored in an SQL database accessed and monitored using sqlite3.
Products, images, and descriptions are retouched/edited versions of products for sale at Boardwise.
Express-generator was used to get up and running (MIT License).
All other modules used are listed in package.json
, and apart from sqlite3
, (which has a BSD-3-Clause Licence), they are all licensed under the MIT License.