mirror of
https://github.com/reactjs/react.dev.git
synced 2026-02-24 20:53:08 +00:00
Remove unused variables (#6574)
This commit is contained in:
committed by
GitHub
parent
30f23d7651
commit
5d2f7105bd
@@ -646,7 +646,6 @@ Arrays are another type of mutable JavaScript objects you can store in state and
|
||||
```js
|
||||
import { useState } from 'react';
|
||||
|
||||
let nextId = 3;
|
||||
const initialList = [
|
||||
{ id: 0, title: 'Big Bellies', seen: false },
|
||||
{ id: 1, title: 'Lunar Landscape', seen: false },
|
||||
@@ -714,7 +713,6 @@ If copying arrays in code gets tedious, you can use a library like [Immer](https
|
||||
import { useState } from 'react';
|
||||
import { useImmer } from 'use-immer';
|
||||
|
||||
let nextId = 3;
|
||||
const initialList = [
|
||||
{ id: 0, title: 'Big Bellies', seen: false },
|
||||
{ id: 1, title: 'Lunar Landscape', seen: false },
|
||||
|
||||
Reference in New Issue
Block a user