React app that exposes that let you perform a search, view a list of results and access a product detail.
It is necessary to first complete the backend installation so when the frontend app runs the backend API is ready to respond.
There are two ways of running the application.
- conteinerized with docker.
- locally with nodejs.
The default port in both cases is 4000, so once the app is running you will be able to find it in your browser at localhost:4000.
You'll need to have docker installed on your machine. Then, in the root of the project, run the following commands.
sudo docker build -t meli-frontend .
sudo docker run -d -p 4000:4000 --name frontend-container meli-frontend
Note: To stop and remove the container:
sudo docker rm -f frontend-container
You'll need to have nodejs v12+ and npm v6.14+ installed on your machine. Then, in the root of the project, run the following commands.
npm i
npm start
Having set up the app locally, you are able to check and see a coverage report with the command.
npm run test