Module 03 · In-depth Understanding of Advanced React Functionality深入理解 React 高级功能
Lab: E-Commerce Data Rendering using Redux Toolkit实验:使用 Redux Toolkit 渲染电子商务数据
In this lab, you will learn how to use Redux Toolkit to manage state throughout your entire application in such a way so that it can be accessed by any component without following the hierarchy between the components. You will build a simple E-Commerce application using React and Redux where you will display a list of products with an “Add to Cart” button for each product, display the items added to the cart and allows users to remove items from the cart. All this information is going to be globally available throughout the application using Redux Toolkit.
在这个实验室中,您将学习如何使用 Redux Toolkit 来管理整个应用程序的状态,以便它可以被任何组件访问,而无需遵循组件之间的层次结构。您将使用 React 和 Redux 构建一个简单的电子商务应用程序,其中将显示产品列表,并为每个产品显示“添加到购物车”按钮,显示已添加到购物车的商品,并允许用户从购物车中删除商品。所有这些信息将通过 Redux Toolkit 在应用程序中全局可用。