This is a Node.js x Express project created by express-generator. It's used to build a application server of reactmovietime.
-
GET /theaters?lat=&lng=&dist= Retrieve the theaters within predefined distance. (default 5 km) query parameters: lat, lng, dist; (optional) user
-
GET /movies?lat=&lng=&dist= retrieve the movies currently on nearby(distance configurable if is registered)
GET /about about page. GET /poster?filmID= retrieve specific film poster GET /movie?filmID=
GET /search?partialFilmNameInZH_TW elasticsearch/sonic ?
POST /login check if already, use passport.js? POST /koremitai/filmID check if already, add to the movie's fav counter POST /logout
POST /forgetpwd send reset mail.
PATCH /user/userID update user profile
DELETE /koremitai/filmID check if already DELETE /user/userID check if logged in.
- Use Jest with Babel 7.
- The files in jest folder are for JEST configuration use.
- Since mongo-memory-server need to create temp folder .cache in node_modules, need to run tests with sudo.
- Run "node --inspect-brk node_modules/.bin/jest --runInBand" in terminal first, then debug in vscode. (Refer to:https://jestjs.io/docs/en/troubleshooting)