mirror of
https://github.com/zebrajr/react.git
synced 2026-01-15 12:15:22 +00:00
Update lists-and-keys.md (#8090)
There is mismatching variable name both definition and usage. In line 156, an argument name called item is change to match the usage in line 158.
This commit is contained in:
@@ -153,7 +153,7 @@ function ListItem(props) {
|
||||
|
||||
function NumberList(props) {
|
||||
const numbers = props.numbers;
|
||||
const listItems = numbers.map((item) =>
|
||||
const listItems = numbers.map((number) =>
|
||||
// Wrong! The key should have been specified here:
|
||||
<ListItem value={number} />
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user