Coder Social home page Coder Social logo

lbs_ad_server's Introduction

Location-based Server

Installation & Setup Environment

1. Fork the repository to your Github

Everyone should use his own repository to develop a new feature, and then make a pull request (PR) for requesting merging the code into master branch. So, first of all, you should click the Fork button which is at the top-left of the Github to make a new copy of the repository to your own. Screenshot

2. Clone the code into your local environment

Use Git clone to clone a mirror copy of code to your dist (Run the command on your terminal):

git clone https://github.com/[YOUR USERNAME]/lbs_ad_server.git

3. Install dependencies

cd lbs_ad_server
npm install
- or - (if using yarn)
yarn

4. Run the server

cd lbs_ad_server
npm run dev-server Note that, if there is error about missing dist/manifest.json , you should run npm run dev for the first time.

Then, you can visit http://127.0.0.1:3000/api/locations to fetch locations data.

5. Use local configuration

Sometimes we use local configurations to make some personal customizing. For example, to use fake api for local development. In this case, you should add your own local_config.js file in root directory. The content of local_config follow the same structure of config.js, but it will overwrite the same key-value in config file. A example of using mock data may like this:

module.exports = {
  useFakeApi: true,
};

6. Enable auto-compile the assets while development

npm run dev More useful scripts can be achieved at package.json.

7. At least, the code should pass lint scripts & CI before making a PR

Switch on Travis CI for you local branch: https://travis-ci.org/profile

Syncing your local branch with the master

1. Configuring the upstream

Following this tutorial: https://help.github.com/articles/configuring-a-remote-for-a-fork/

2. Syncing the local branch

git checkout master
git fetch --all
git rebase upstream/master
git push

Note that, each time when you develop a future, you should use a separated branch.

git checkout -b [the new branche nanme]

Tech Stacks

  1. Express.js
  2. Faker.js

May be used in future:

  1. Sequelize
  2. Passport.js

lbs_ad_server's People

Contributors

hustkiwi avatar

Watchers

 avatar James Cloos 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.