Dynamic API Phase 1: Build your core, standards compliant Express server. From a business requirements standpoint, we will be building a basic Express server using best practices, including server modularization, use of middleware, and tests.
- Method: GET
- Path: /person
- Expects a query string from the user with a “name” property
- When present, output JSON to the client with this shape: { name: "name provided" }
- Without a name in the query string, force a “500” error
Referenced Ryan Gallaway's Demo Code CodeFellow TA's for assistance with server.js and server.test.js issues
Port variable located within .env.sample
- e.g.
npm start
Clone repo, npm i, then run nodemon in terminal
- Feature One: Details of feature
- GET :
/person
- specific route to hit with query?name=name
To Run tests, run the command npm test