When a user experiences a “cat-call” they can quickly log the location and their response and view other locations where cat-calls have occured.
- Fork to your github
- Clone to your local
- Checkout your own branches for new features
- During development Pull from master
- Push origin
- Make Pull Request
- Team Approves
- 👏
After cloning this repository, a simple call to npm i
or yarn
will install many of the packages locally that you will need.
Next, a call to either npm run dev
or yarn dev
will get you started and run the express server and a separate server hosting the react app simultaneously and in development mode. By default, the express server will be accessible at http://localhost:3001
and the separate server hosting the react app will be accessible at http://localhost:3000
.
See Deployment for notes on how to deploy the project on Heroku.
- First and foremost, you will need to have Node.js and npm downloaded and installed
a. If you check the
package.json
file you'll notice that your major version of Node.js should be8
and your major version of npm should be5
(this is so you will have access tonpx
) b. [Optional] If you find yourself switching between node versions often for various projects or repositories, consider using nvm - Once you have Node and npm installed at the right versions, run
to install
npm i -g nodemon
nodemon
, which will be used for development. - You will also need a
.env
file in the root directory of inside where you cloned this repository. See Environment Variables for what environment variables you will need and what they will refer to. - For deployment considerations, you will also need to have the Heroku CLI installed
End with an example of getting some data out of the system or using it for a little demo
You won't need to worry about manually setting environment variables. Instead, this project is meant to use a .env
file
With descriptions instead of values, this is what your .env
should look like (noting that currently the database is assumed to be a MongoDB instance):
DB_NAME=<database name>
DB_PORT=<database port>
DB_HOST=<database host>
DB_USER=<database username, for authentication>
DB_PASS=<database password, for authentication>
LOG_LEVEL=info # the server will use this log level to ignore anything not important enough to appear in the console
REACT_APP_API_HOST=http://localhost # the client will use this host to contact the server
REACT_APP_API_PORT=3001 # the client will use this port to contact the server
- React
16.2.0
- The front-end framework used - dotenv - To manage configuration of environment variables
- babel
^6.26.0
- For production, to transpile the server-side es6+ into a static production-grade version - babel-register
^6.26.0
- For development, to transpile the server-side es6+ just-in-time - express
~4.15.5
- The server-side framework used - Mongoose - To help deal with object models
- express-generator - To generate the express server-side
- create-react-app - To generate the react app
This project is licensed under a Creative Commons Attribution 4.0 International License.
- PurpleBlooth, for their README template
- All the wonderful people of bridge