Prop Fetching: load product data from API
rconjoe opened this issue · 0 comments
rconjoe commented
Add routes to your next.js API that return:
- All products
/api/products
- An individual product, based on ID:
/api/products/:id
Call those new routes to load product data into your /products
page. Use the following prop fetching methods and be prepared to explain the difference between the two: