Digital portfolio website for Montgomery Hatch
- Install MongoDB
-
Install Node.js
-
Retrieve project dependencies
In project root run
$ npm install
-
Set mail client
Set the username/password in /api/routes/mailRoute.js
-
Connect to database
In /api/server.js update
mongoose.connect()
with your db connect string. For local development usemongodb://127.0.0.1:27017/{database name}
-
Start NodeJS server
Navigate to /api and run
node server.js
Default port is 3000, you can set this in /api/server.js
-
Add data
You may add data using the mongo command line interface or by using the REST API endpoints defined in /api/server.js
webpack-dev-server
webpack -p
npm run test
Note: In a production environment you will need to update the URI for the REST API in /src/components/main.jsx