Skip to content

Commit 8de5115

Browse files
committed
Translate comments
1 parent 76931a6 commit 8de5115

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

content/docs/hooks-state.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ La [página anterior](/docs/hooks-intro.html) introdujo los Hooks con este ejemp
1414
import { useState } from 'react';
1515
1616
function Example() {
17-
// Declare a new state variable, which we'll call "count"
17+
// Declaración de una variable de estado que llamaremos "count"
1818
const [count, setCount] = useState(0);
1919
2020
return (
@@ -68,7 +68,7 @@ Como recordatorio, un componente funcional en React es así:
6868

6969
```js
7070
const Example = (props) => {
71-
// You can use Hooks here!
71+
// Puedes usar Hooks aquí!
7272
return <div />;
7373
}
7474
```
@@ -77,7 +77,7 @@ o así:
7777

7878
```js
7979
function Example(props) {
80-
// You can use Hooks here!
80+
// Puedes usar Hooks aquí!
8181
return <div />;
8282
}
8383
```
@@ -126,7 +126,7 @@ En un componente funcional no existe `this` por lo que no podemos asignar o leer
126126
import { useState } from 'react';
127127
128128
function Example() {
129-
// Declare a new state variable, which we'll call "count"
129+
// Declaración de una variable de estado que llamaremos "count"
130130
const [count, setCount] = useState(0);
131131
```
132132

@@ -142,7 +142,7 @@ Ahora que sabemos que hace el Hook `useState`, nuestro ejemplo debería tener m
142142
import { useState } from 'react';
143143
144144
function Example() {
145-
// Declare a new state variable, which we'll call "count"
145+
// Declaración de una variable de estado que llamaremos "count"
146146
const [count, setCount] = useState(0);
147147
```
148148

@@ -262,7 +262,7 @@ En el componente de arriba tenemos `age`, `fruit`, y `todos` como variables loca
262262
263263
```js
264264
function handleOrangeClick() {
265-
// Similar to this.setState({ fruit: 'orange' })
265+
// Similar a this.setState({ fruit: 'orange' })
266266
setFruit('orange');
267267
}
268268
```

0 commit comments

Comments
 (0)