This is a web application that demonstrates an ecommerce website with a list of products on the home page, and allows users to add products to their cart and favorites list. The app also includes a navigation bar with two pages to view the cart and favorited products, with the ability to cancel the operation at those pages. The state is managed with the useState hook and shared between pages using the context provider.
- Display a list of products on the home page
- Add products to cart and favorites list
- View cart and favorites list on separate pages
- Ability to cancel the operation at cart and favorites list pages
- State management with useState and context provider
- React JS
I built this project to practice my skills in React JS, specifically with state management and context provider. Ecommerce websites are a great way to learn how to manage state in a complex application, and sharing state between pages can be a challenging but rewarding experience.
To run this app on your local machine, follow these steps:
- Clone the repository
- Install the dependencies by running
npm install
- Start the development server with
npm start
That's it! You should now be able to view the app in your browser at http://localhost:3000
.
If you find a bug or have a suggestion for how to improve this app, feel free to open an issue or submit a pull request. Contributions are always welcome!