W01fw00d / cooking-with-amateurs

Cooking Recipes App. Uses Chemistry-UI
0 stars 0 forks source link
cypress jest mangoose mongodb node-js react react-hooks typescript
Cooking with aMateuRS Logo

Node.js CI

Demo of the App

How to use

Dev Environment

  1. Install dependencies
npm install
  1. Deploy Front App
npm run dev-front
  1. Deploy Back App

Install and run a MongoDB instance and then:

npm run dev-back

"npm link" is useful, but there are some issues regarding having multiple "react", "react-dom" and "react-router-dom" instances running.

To solve this, you can execute this script that will perform the correct linking:

npm run dev-link
npm run utest

Launch with coverage

npm run utest-cover

Open '.../coverage/lcov-report/index.html' to see the coverage report

npm run dev-front

Run on console (mobile screen by default)

npm run ftest-mobile

Run on console (desktop screen)

npm run ftest-desktop

Run all scenarios with a @core tag (critical test cases)

npm run ftest-core

Run with Cypress UI

npm run ftest-ui

Prune your cache:

./node_modules/.bin/cypress cache clear

Then install cypress:

./node_modules/.bin/cypress install --force

Prod Environment

  1. Set the MONGODB_URL environment variable in your node environment with your DB URL.

In Heroku, that can be done using Config Vars.

  1. Install dependencies
npm install
  1. Build the Frontend code
npm run build
  1. Run the Production Server
npm run start
npm run dev-start

Functional description

Technical Stack



Technical discussion

Attribution