This free course is dedicated to our martyrs ❤
In each session, kindly recite a Salawat (blessing upon the Prophet and his family) for the martyr named in the subtitles or caption of the video.
- Session 1
- Create and Setup Project
- JSX
- Session 2
- Event Handling
- useState
- Components
- Props
- Session 3
- Behind The Scenes
- The
keyAttribute
- Session 4
- Styling
- Home Page
- React Router
- Layouts
- Session 5
- Board Page
- Session 6
- React DevTools
- memo
- useMemo
- useCallback
- Session 7
- localStorage
- useEffect
- useLayoutEffect
- StrictMode
- Session 8
- Prop Drilling
- Context
- useReducer
- React-Toastify
- Session 9
- Modal Component
- Form Validation
- Uncontrolled Form vs Controlled Form
- Session 10
- dnd kit (Drag and Drop)
- Session 11
- New Features
- CRUD Operations (Create, Read, Update, Delete)
- Practice Working With Forms
- Session 12
- Zod
- Session 13
- React Hook Form
- Session 14
- Deploy
- Domain
- Sidebar Component
- Session 15
- Zustand
- Dark Mode
- Migrate Boards From Context to Zustand
- Session 16
- How the Web Works?
- Postman
- Backend Project Introduction
- Online API
- Modal Store
- Session 17
- Authentication
- Session 18
- Floating UI
- Session 19
- Settings Page
- Auth Guards
- Custom Hooks
- Session 20
- Connect Boards to API
- React Query
- Session 21
- Responsiveness
- Session 22
- i18next (Internationalization)
- Session 23
- Rules of React
- Design Patterns
Dedicated to امام حسین علیهالسلام ❤
- Roadmap Overview
- Concept and Idea: Kanban Boards Management System
- Demo (Trello)
- Free but Requires Salawat for Each Session
- Proficiency in HTML, CSS, JavaScript
- Familiarity With TypeScript
- Familiarity With npm or Any Other Package Manager
- Familiarity With Git and GitHub
- Vite
- Why Not CRA?
- File and Folder Structure
- Remove Unnecessary Files
- Remove Unnecessary Code
- Remove StrictMode
- Add
favicon.ico - Add
.idea/and.vscode/to.gitignore - Update
titleinindex.html - Update
README.mdto Only Include Heading - Hello, friend!
- Start the Project
- Initialize Project With Git
- Create a Repo on GitHub
- Set Remote URL in Git
- Push the Project to GitHub
- Create a New Branch Called
session-1
- Install Prettier
- Config WebStorm to Run Prettier on Save
- Add Import Alias Configs to
tsconfig.app.jsonandvite.config.ts - Install
@types/node - Install
@trivago/prettier-plugin-sort-imports - Setup Prettier Configs
- Run Prettier for All Files
- Add Stricter Rules to ESLint
- Add
ReactNodetoApp.tsx - Move
export defaultto Function Declaration, so It Will Match Future Components
- Why? and What?
- Rules
- Wrap Multi-line Code in Parentheses
- Return a Single Root Element
- Fragment or <>
- Close All the Tags
- Use camelCase Attributes
- Use
classNameInstead ofclass - Use
htmlForInstead offor
- Use Variable in JSX
- Use JavaScript Code in JSX
- Use Loops in JSX
- Use Conditions in JSX
- Ternary
&&
- Use Separate Variable to Contain JSX
- https://babeljs.io/repl
- ReactElement
- ReactNode
- JSX.Element
Dedicated to شهید محمدهادی ذوالفقاری ❤
- Separate Regular Function
- Separate Arrow Function
- Inline Arrow Function
- Inline Regular Function
- You Must Pass the Function Itself and Not Call it
- TypeScript
- My Standard
- Name Should Start With
handelLikehandleClick - Return Type Should be Written Explicitly
- Name Should Start With
- How to Update DOM When a Variable Changes?
- Local variables Don't Persist Between Renders
- Changes to Local Variables Won't Trigger Renders
useStateIntroduction and Syntax- Passing Simple Value to
setState - Initial Value (Simple)
- Initial Value (Function)
- Multiple States
- Passing Function to
setState- Show the Bug
- Why?
- Fix the Bug
- Updating Objects in State
- Immutability
- Spread Syntax
- Updating Arrays in State
- Why? and What?
- Syntax
- Use Like an Element
- Move to a Separate File
- Export and Import
- State is Isolated and Private
- Passing Data from Parent to Child
- Non-state Props
- State Props
- Event Handler Props
- Custom Events (Passing Data from Child to Parent)
- Naming Convention
- Children
- As Attribute
- As Child Element
- Optional Boolean Props Conventions
- Name Them Without "is"
- Optional
- Default Value
- Use Them Without Assignment
Dedicated to شهید محمد بروجردی ❤
https://react.dev/learn/render-and-commit
- SPA
createRootandrender- Triggering
- Initial Render
- State Change in Current Component or One of Its Ancestors
- Rendering
- Simply Calling Functions (Components)
- In Initial Render, The Root Element and All of its Children Are Called
- In Re-renders, Only the Component that Triggered the Re-rendering and its Children Are Called
- Virtual DOM
- Commiting
- The Diffing Algorithm
- Re-rendering and Repeating Above Steps
- Show the Bug
- Why?
- How to Fix It
- Console Error
Dedicated to شهید فریدون عباسی ❤
- Global Styles
- Normal CSS
- The Problem
- CSS Modules
- User Can See List of Boards
- Button to Create a New Board
- File and Folder Structure of Components
- Turn Board Card Into Its Own Component
- Turn Button Into Its Own Component
- Variants: Solid, Outlined
- Colors: Default, Primary
- Why? and What?
- Install
- Setup
- Features
- Header Component
- Logo and Title (Navigates to Home Page With Link Component)
- Board Card Component (Navigates to Selected Board Page)
- Why We Should Use Link Component Instead of Anchor Element?
- Footer Component
- Dynamic Year
- Without
useStateBecause It Won't Change and Won't Cause Re-rendering
- Without
- Copyright Symbol
- Dynamic Year
- Dynamic Routes for Boards
- Get Board ID From URL and Show It In the Page
- Global Not Found Page (404)
- Global Error Handler Page
- Why? and What?
- Setup
- Header Component
- main
- Footer Component
- Refactor Pages and Styles
Dedicated to شهید مصطفی احمدی روشن ❤
- Board Component
- Implement the Design With Mock Data
- Static Lists (To Do, Doing, Done)
- List Items (Only Title)
- List Type
- List Item Type
useStatefor Each list- List Component
- Props: Array of List Items
- Content: Title, Create Button, List Items
- List Item Component
- Remove List Item
- Click on a Button That Lives Inside Board Page
- It Always Removes Second Item With Index of 1
Dedicated to شهید سید ابراهیم رئیسی ❤
- Why? and What?
- Install
- Components Panel
- Profile Panel
- Show How All List Items Re-renders When One Item Changes
- Why?
- Fix It With
memo
- Show How Other Lists Re-render When the Other One Changes
- Fix It With
memo
- Sort Lists Before Passing Them to Components
- Memoization Doesn't Work Anymore; Why?
- Fix It With
useMemo - We Need Both
memoanduseMemofor This to Work useMemoUsage Withoutmemofor Heavy Computations
- Remove List Item
- Click on the Item You Want To Remove
- You Need a Custom
onClickEvent for List Component
- Re-rendering Issue Comes Back
- Doesn't Work; Why?
- Fix It With
useCallback
- Merge List States Into One State
- Move Lists Data to a Separate File
- Click on the Item You Want To Remove
- A Remove Button Will Appear on Toolbar
- Clicking on the Button Will Remove the Item From the List and Also Hides the Button Again
- Click on the Item You Want To Move
- Two Move Buttons Will Appear on Toolbar for the Other Two Lists
- Clicking on Any Button Will Move the Item to the Desired List and Also Hides Buttons Again
- Fix Re-rendering Issue That Is Caused by the New Logic
- Add Full Memoization to Board Component and All of Its Children
- According To React Docs, We Only Need To Do This if It's Causing Performance Issues
- In New Versions, React Compiler Will Do This for Us
- We Still Need to learn this
- React Compiler Is Currently in Release Candidate (RC) State
- React Compiler Isn't Always Available in a Project
- Understanding These Concepts Helps To Avoid Potential Mistakes That Prevents React Compiler to Memoize a Project
- These Will Be Asked in Interviews
Dedicated to شهید مسعود علیمحمدی ❤
- Create a List Item With a Random Title
- We Want to Save State to
localStorageand Retrieve It on Page Reload - Create a Save Function That Does This
- Call It Separately on Create, Move and Remove Functions
- Retrieve It in
useStateInitial Function
- Currently, We Are Calling Save Function From Three Different Places
- All We Want Is to Get Noticed When State Changes
- Other Than That, The State Might Change Some Other Way
- Fix It With
useEffect
- Why? and What?
- Add It to the Project
- Show It With
console.log - Show It With React DevTools
- Note: If React DevTools Is Installed, It Will Gray Out Second Logs
- Why? and What?
- The Difference Between
useEffectanduseLayoutEffect - Show the Example in React Doc
- We Don't Need It in This Project, but It Might Be Asked in an Interview
Dedicated to شهید مجید شهریاری ❤
- Add a Remove Button to List Item Component
- You Need to Pass Callback Function Through List Component
- This Is Called Prop Drilling
- We Need to Fix Prop Drilling
- State Logic Got Too Complicated and Is Being Used by Multiple Components
- Fix It With Context
createContextContext.ProvideruseContextuse
- State Logic Got Too Complicated
- We Are Changing State Via Certain Ways
- Fix It With
useReducer
- Why? and What?
- Install
- Setup
- Show Toasts When Creating, Moving and Removing List Items
Dedicated to شهید داریوش رضایینژاد ❤
dialogHTML Element- Access the Element by
useRef, so We Can Open and Close It - Implement the Design
- Close by Clicking on the Backdrop
- Uses Modal Component Internally
- Text Input Component
- Add
useIdfor Input'sidand Label'shtmlFor
- Add
- Add Form Element
- Only Put Title Input for Now
onSubmitformData
- Add a Simple Validation on Submit
- Add Error Message With
useStateand Conditional Rendering
- Why? and What?
- We Use Controlled Forms When We Care About State Change and Want to Get Notified
- Currently, We Validate Inputs Only When User Submits the Form
- Refactor to Controlled Form, so We Can Revalidate on Change After First Submission
Dedicated to شهید حسن طهرانی مقدم ❤
- Why? and What?
- Install
- Setup
- Reorder List Items
- Move List Item to Another List
- Reorder Lists
Dedicated to شهید علی صیاد شیرازی ❤
- Create List
- Remove List
- Rename List
- New List Item Fields
- Description
- Due Dates (Change Color When Due Soon or Overdue)
- View and Edit List Item
- Create Board
- Rename Board
- Remove Board
Dedicated to شهید محمد باقری ❤
- Why? and What?
- Install
- Setup
- Migrate Old Validations to Zod
Dedicated to شهید امیرعلی حاجیزاده ❤
- Why? and What?
- Install
- Setup
- Migrate Old Forms to React Hook Form
- Connect Zod to React Hook Form
Dedicated to شهید حاج قاسم سلیمانی ❤
- Why? and What?
- Create a New Project in Vercel
- Automatically Deploy on Push
- How to Buy a Domain?
- Connect Domain to Vercel
- Expanded Mode
- Logo With Title
- Home Icon With Title
- Individual Boards Listed With Full Titles (Ellipsis)
- Collapsed Mode
- Logo
- Home Icon
- Individual Boards Listed With Initials
Dedicated to شهید محسن فخریزاده ❤
- Why? and What?
- Install
- Setup
- Create Sidebar Store
isCollapsedfold()
- Refactor Sidebar Component
- Persist State With
localStorage
- Create Theme Store
themetoggleTheme()
- Theme Switch Component in Sidebar
- Set
data-themeAttribute onhtmlElement - Add CSS
color-schemeand Color Variables - Read
themefrom Store in React-Toastify Provider - Persist State With
localStorage
- Create Kanban Store
- Create Boards Slice
boardscreateBoard()editBoard()removeBoard()
- Create Lists Slice
createList()editList()removeList()moveList()
- Create Items Slice
createItem()editItem()removeItem()moveItem()moveItemBetweenLists()
- Persist State With
localStorage
Dedicated to شهید حسین سلامی ❤
- Network
- Definition
- PAN
- LAN
- MAN
- WAN
- Internet
- IP
- DNS
- API
- Why? and What?
- Server and Clients
- Frontend and Backend
- HTTP
- Web Architecture
- Methods
- Headers
- Status Codes
- URL
- Request
- Response
- Params
- JSON Body
- Multipart Form Data
- HTTP vs WebSocket
- Why? and What?
- Install
- Setup
- How To Use?
- Introduce the Repo
- Environment Variables
- How To Run the Backend Project?
- Use Postman To Send Requests
- Students Can Use api.canban.ir
- Create Store
renderModalshowModal()closeModal()
- Create Modal Container
- Only Show One Modal at a Time
Dedicated to شهید ابراهیم هادی ❤
- How It Works? (Cookies and Tokens)
- Reference The Auth Videos In My Channel
- Use
fetchto Call API - Sign Up, Sign In, Sign Out
- Let User Sign Up With Random Credentials
- Let User Choose if They Want To Use Sample Data
Dedicated to شهید بهشتی ❤
- Dynamic Size Based on
font-size - Placeholder Initials
- Placeholder Random Color
- Why? and What?
- Install
- Setup
- Features
- Avatar
- Username
- Floating UI
- Boards
- Settings
- Sign Out
Dedicated to شهید مطهری ❤
- View and Edit User Settings
- Sign Out
- Why? and What?
- Logged In Only Guard
- Guess Only Guard
- Why? and What?
- Conventions
useUserCustom Hook
Dedicated to شهید آرمان علیوردی ❤
- Completely Migrate From Zustand Except Dark Mode and Sidebar
- Why? and What?
- Install
- Setup
- Features
- Refactor
Dedicated to شهید روح الله عجمیان ❤
- Make Whole Project Responsive
Dedicated to شهید ادواردو آنیلی ❤
- Why? and What?
- Install
- Setup
- Features
- Refactor All Texts to Translated
Dedicated to تعجیل در فرج امام زمان علیهالسلام ❤
- Components and Hooks must be pure
- React calls Components and Hooks
- Rules of Hooks
- DRY
- KISS
- YAGNI
