Skip to content

Commit 515b646

Browse files
authored
Update part1c.md
The variable gets assigned a function, not to a function.
1 parent 299c5b7 commit 515b646

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/content/1/en/part1c.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ const [ counter, setCounter ] = useState(0)
300300
301301
The function call adds <i>state</i> to the component and renders it initialized with the value of zero. The function returns an array that contains two items. We assign the items to the variables _counter_ and _setCounter_ by using the destructuring assignment syntax shown earlier.
302302
303-
The _counter_ variable is assigned the initial value of <i>state</i> which is zero. The variable _setCounter_ is assigned to a function that will be used to <i>modify the state</i>.
303+
The _counter_ variable is assigned the initial value of <i>state</i> which is zero. The variable _setCounter_ is assigned a function that will be used to <i>modify the state</i>.
304304
305305
The application calls the [setTimeout](https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout) function and passes it two parameters: a function to increment the counter state and a timeout of one second:
306306

0 commit comments

Comments
 (0)