From 467f15630ae8a0436e167c329146ad25a6c58e2c Mon Sep 17 00:00:00 2001
From: sodiel <68740147+sodiel@users.noreply.github.com>
Date: Thu, 22 Jan 2026 17:37:52 +0300
Subject: [PATCH] use 'dependency array' instead of 'table'
---
src/content/2/en/part2e.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/content/2/en/part2e.md b/src/content/2/en/part2e.md
index 6775162b815..1f75549b036 100644
--- a/src/content/2/en/part2e.md
+++ b/src/content/2/en/part2e.md
@@ -541,7 +541,7 @@ const App = () => {
}
```
-The useEffect hook now has _[currency]_ as the second parameter. The effect function is therefore executed after the first render, and always after the table as its second parameter _[currency]_ changes. That is, when the state _currency_ gets a new value, the content of the table changes and the effect function is executed.
+The useEffect hook now has _[currency]_ as the second parameter. The effect function is therefore executed after the first render, and always after the dependency array as its second parameter _[currency]_ changes. That is, when the state _currency_ gets a new value, the content of the dependency array changes and the effect function is executed.
It is natural to choose _null_ as the initial value for the variable _currency_, because _currency_ represents a single item. The initial value _null_ indicates that there is nothing in the state yet, and it is also easy to check with a simple if statement whether a value has been assigned to the variable. The effect has the following condition