This simple shopping cart prototype shows how React components and Node Js can be used to build a friendly user experience with instant visual updates and scaleable code in ecommerce applications.
- Add and remove products from the cart
- Sort products by highest to lowest and lowest to highest price
- Search products for all categories.
- Filter products by categories
- Products persist in cart even after page reloads
- Responsive design for desktop and mobile
- Unit tests, integration tests and e2e testing
- React
- Hooks- state management
- Nodejs
- Express
- Nodemon - for a better development experience
- Axios - for promise HTTP requests
- CSS
- SASS
- Native local storage - to persist products in cart even after page reload
-
First, Install the needed packages
- yarn (can also use npm install)
-
To start Node
- Assuming node is installed(if not please install node)
- nvm use (if needed)
- node server
- Assuming node is installed(if not please install node)
-
To start React
- yarn start / npm start
-
To run test cases
- yarn test / npm test