Giter Site home page Giter Site logo

codelabs-nodejs's Introduction

API User

What is this?

  • User service API for web & mobile apps

How do I get set up?

  • Install Node.js v8.6.0

  • Install npm v5.3.0

  • Install project dependencies:

    • Install all dependencies defined in package.json:

      npm install

  • Setup environment variables

    This project uses dotenv, please configure the proper environment variables before running this application.

    • Copy the .sample-env file and rename it to .env
    • Edit all sample fields with the correct environment variables for the application server
  • Database migration (using Sequelize):

    • create model (and migration): node node_modules/.bin/sequelize model:create --name <model_name> --attributes <attributes>
    • create migration: node node_modules/.bin/sequelize migration:create
    • run: node node_modules/.bin/sequelize db:migrate
    • undo: node node_modules/.bin/sequelize db:migrate:undo
    • help: node node_modules/.bin/sequelize help
  • How to run tests:

    npm test

  • Deployment instructions

    npm start or node index.js

Contribution guidelines

  • Writing tests:

    This project use Mocha as the testing environment, and Chai as the assertion library. This project also provide code coverage using Istanbul. Code coverage report can be viewed in coverage/lcov-report/index.html after running test. All test files should be located under the tests directory.

  • Writing code:

    Please fork this repository first for starting a contribution. This project use ESLint as Javascript lint library.

    • To run ESlint, type node node_modules/.bin/eslint .
    • Fixing code errors, just type node node_modules/.bin/eslint . --fix

Who do I talk to?

© Rakhmatullah Yoga Sutrisna - PT GITS Indonesia 2017

codelabs-nodejs's People

Contributors

rezamaskadi avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.