A lightweight app for parsing and invoice in JSON format and updating a database.
- Drag and drop a valid JSON invoice into the box.
- File is uploaded to the server, parsed recorded to the database and emitted on the socket
- All users receive real-time update
- Angular (ES6)
- Express
- Socket.io
- Webpack
- Gulp
- SASS
- Install the latest Node.js and NPM. This config is built with Node V6.2.0.
- Webpack
npm install webpack -g
and ensure it is available on your PATH - Gulp
npm install gulp -g
and ensure it is available on your PATH
For development tools and building:
- Run
yarn
ornpm install
within the project root directory in Terminal. - Change directory
cd ./public
and runyarn
ornpm install
again for the client side dependencies. - Back to project root
cd ../
- Run
npm start:dev
to start the server. - Run
npm run build:watch
to run webpack and watch for changes. - Run
npm test
to run Karma tests and watch for changes. - Run
gulp build:watch
to process our stylesheets. Webpack also sees there changes and modifies the bundle.
/public/components
contains a sub-directory for each component, holding source JS and views./public/style
contains a sub-directory for each style component, folder scss for the source styling and css for the compiled version./public/dist
is the directory for webpack compiled JS and CSS/routes
API and models definition/.config/.env
stores global variables for the server/.config/.db
Database connection params
Command | Purpose |
---|---|
npm run clean |
Delete /public/dist/* . |
npm run build |
Compile JS and CSS to /public/dist/bundle . |
npm run build:watch |
Build, rebuilding on source file changes. |
npm run start:dev |
Start the server, restarting on source file changes. |
npm run start:prod |
Start the server using forever in production mode |
npm run stop:prod |
Stop the production server |
npm run restart:prod |
Restart the production server |
npm start |
Start the server. |
npm test |
Start Karma testing watching for file changes. |
Developed by Jimmy Cann and licensed under MIT.