fix(curriculum): correct grammar in React state and hooks review (#64588)

This commit is contained in:
KULDEEP KUMAR
2025-12-15 00:08:19 +00:00
committed by GitHub
parent 0cd88a07f8
commit 6836c5ded6
@@ -51,8 +51,8 @@ function handleDelete(id) {
## Working with State and the `useState` Hook
- **Definition for state**: In React, state is a object that contains data for a component. When the state updates the component will re-render. React treats state as immutable, meaning you should not modify it directly.
- **`useState()` Hook**: The `useState` hook is a function that lets you declare state variables in functional components.  Here is an basic syntax:
- **Definition for state**: In React, state is an object that contains data for a component. When the state updates the component will re-render. React treats state as immutable, meaning you should not modify it directly.
- **`useState()` Hook**: The `useState` hook is a function that lets you declare state variables in functional components. Here is the basic syntax:
```js
const [stateVariable, setStateFunction] = useState(initialValue);