April 2020
Intermediate to advanced
716 pages
18h 55m
English
The MyShops component is similar to the Shops component. It fetches the list of shops owned by the current user, and renders each shop in a ListItem, as pictured in the following screenshot:

Additionally, each shop has an edit and a delete option, unlike the list of items in Shops. The implementation for the MyShops component is the same as Shops, except for these edit and delete buttons, which are added as follows:
mern-marketplace/client/shop/MyShops.js:
<ListItemSecondaryAction> <Link to={"/seller/shop/edit/" + shop._id}> <IconButton aria-label="Edit" color="primary"> <Edit/> </IconButton> </Link> <DeleteShop shop={shop} ...Read now
Unlock full access