yogeshtakeo / BFS33_files

0 stars 0 forks source link

Task 10 : Product Displaying Page with Redux Toolkit Query #16

Open yogeshtakeo opened 1 year ago

yogeshtakeo commented 1 year ago

Full Stack Development Bootcamp - Redux Toolkit Query Task with Product Page

Task Description

In this task, you will utilise Redux Toolkit Query to fetch product data from the Fake Store API and create a product page in your Vite + React application. You are encouraged to use any UI library of your choice (e.g., Material UI, Tailwind CSS, Daisy UI, Flowbite UI) to enhance the UI. Additionally, follow the directory-per-component pattern for organising your code, implement a loading indicator for RTK Query, add correct type references with TypeScript, and create a proper card implementation to display the products.

Prerequisites

Before you begin, ensure you have the following installed on your system:

Task Steps

Step 1: Set Up a Vite + React Project

  1. Open your terminal and navigate to the directory where you want to create your project.

  2. Run the following command to create a new Vite + React project using create-vite@latest:

    npx create-vite@latest redux-query-product-page --template react
  3. Navigate into your project directory:

    cd redux-query-product-page

Step 2: Follow the Directory-per-Component Pattern

  1. Create a separate directory for each component you'll be building (e.g., ProductPage, CardComponent).
  2. Organise your components, styles, and related files within their respective directories.

Step 3: Install and Configure RTK Query

  1. Install Redux Toolkit and RTK Query as dependencies:

    npm install @reduxjs/toolkit react-redux
  2. Set up your Redux store and configure RTK Query according to the official documentation.

Step 4: Fetch Data using RTK Query and Implement Card Component

  1. Open the file where you will define your RTK Query API service. Create a new API endpoint to fetch product data from the Fake Store API using RTK Query.
  2. Create a proper card component to display the products. Style the card component using the chosen UI library.

Step 5: Create a Product Page

  1. Create a React component named ProductPage in a suitable directory (e.g., src/pages).
  2. Use the useQuery hook from RTK Query to fetch and display the product data on the ProductPage component.

Step 6: Implement Navigation and UI Library

  1. Choose a UI library (e.g., Material UI, Tailwind CSS, Daisy UI, Flowbite UI) for styling.
  2. Implement a navigation bar that allows navigation to the ProductPage component.
  3. Style your components using the chosen UI library.

Step 7: Loading Indicator and Type References

  1. Implement a loading indicator for your RTK Query component.
  2. Ensure you have the correct type references in your components when using TypeScript.

Step 8: Run the Development Server

  1. Start the development server by running:

    npm run dev
  2. Open your browser and navigate to http://localhost:3000 to see your Vite + React app with the product page, RTK Query, and enhanced UI in action.

Task Completion

Congratulations! You've successfully completed the Redux Toolkit Query task with a product page. You've learned how to use RTK Query to fetch and display product data, implement navigation, style your components using a UI library, organise your code using the directory-per-component pattern, implement a loading indicator, and use proper type references with TypeScript.

Submission

Please follow the submission process below:

  1. Take a screenshot of your completed application showcasing the product page, RTK Query, and the enhanced UI.
  2. Open a new issue in this repository.
  3. Paste the submission screenshot in the issue.
  4. Provide the following details in the issue:
    • Name: Your name
    • GitHub URL: Your GitHub repository URL for this task

Your submission will be reviewed, and feedback will be provided through the same issue.

Further Learning

To further enhance your skills with RTK Query, explore more advanced features such as caching, mutations, and pagination. Refer to the official documentation for comprehensive guidance.

Conclusion

Great job on completing this comprehensive Redux Toolkit Query task with Vite + React and creating a product page! You've gained valuable experience in using RTK Query to manage data fetching, designing a user-friendly UI using your chosen UI library, organising your code using the directory-per-component pattern, implementing a loading indicator, and using proper type references with TypeScript. Keep exploring and building with Redux Toolkit and RTK Query!

RoneshSingh commented 1 year ago

Name : Annish Singh Group : 3 (Annish, Nayan, Yash) Github : https://github.com/RoneshSingh/Product-Displaying-Page-with-Redux-Toolkit-Query Github Forked From: https://github.com/YashKharel19/Product-Displaying-Page-with-Redux-Toolkit-Query

Image

GM-Frost commented 1 year ago

Name: Nayan Main Github Link: https://github.com/YashKharel19/Product-Displaying-Page-with-Redux-Toolkit-Query Forked Github Link: https://github.com/GM-Frost/Product-Displaying-Page-with-Redux-Toolkit-Query.git Team 3: (Anish, Nayan, Yash) image

Untitled

YashKharel19 commented 1 year ago

Name: YASH Main Github Link: https://github.com/YashKharel19/Product-Displaying-Page-with-Redux-Toolkit-Query ULPOADED MAIN SKELETON Team 3: (Anish, Nayan, Yash) app product store

onsever commented 1 year ago

Name: Onurcan Main Github Link: https://github.com/shreeshakhadka/ReduxToolKit Forked Github Link: https://github.com/onsever/ReduxToolKit Team 1 (Shreesha, Bijaya, Onurcan)

shreeshakhadka commented 1 year ago

Name: Shreesha Khadka Github URL: https://github.com/shreeshakhadka/ReduxToolKit Group1 : Shreesha, Onurcan, Bijay

Image

Image

Image

bjornbaniya commented 1 year ago

Name - Bijaya

Main Link: https://github.com/shreeshakhadka/ReduxToolKit

Forked Github Link: https://github.com/bjornbaniya/ReduxToolKit

Team - 1

Task: Product-Displaying-Page-with-Redux-Toolkit-Query

Image

Image

Image

Image

bjornbaniya commented 1 year ago

šŸ‘Duplicate Submission

ngawangsherpa commented 1 year ago

Name: Ngawang Sherpa Main Github Link: https://github.com/ngawangsherpa/ReduxToolkitQuery Team 2: (Ngawang, Swastika, Shailendra)

Screenshot 2023-08-17 at 5 09 03 PM Screenshot 2023-08-17 at 5 08 39 PM Screenshot 2023-08-17 at 4 20 42 PM
swskasingh commented 1 year ago

name : swatika singh github link : https://github.com/swskasingh/ReduxToolkitQuery group 2

Image

shailendrayadav7 commented 1 year ago

Name: Shailendra Yadav GitHub: https://github.com/shailendrayadav7/ReduxToolkitQuery Group 2

261444538-b5450555-b2d1-466f-9b67-9f321d2c06e5