You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/reference/react/cloneElement.md
+10-10Lines changed: 10 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -137,7 +137,7 @@ Children’larını clone ederek, `List` her bir `Row`’a ekstra bilgi geçireb
137
137
</List>
138
138
```
139
139
140
-
Notice how pressing "Next" updates the state of the `List`, and highlights a different row:
140
+
“Next” butonuna basıldığında `List`’in state’inin nasıl güncellendiğine ve farklı bir satırın highlight edildiğine dikkat edin:
141
141
142
142
<Sandpack>
143
143
@@ -232,21 +232,21 @@ button {
232
232
233
233
</Sandpack>
234
234
235
-
To summarize, the `List`cloned the `<Row />`elements it received and added an extra prop to them.
235
+
Özetle, `List`aldığı `<Row />`elementlerini clone etti ve bunlara ekstra bir prop ekledi.
236
236
237
237
<Pitfall>
238
238
239
-
Cloning children makes it hard to tell how the data flows through your app. Try one of the [alternatives.](#alternatives)
239
+
Children’ları clone etmek, veri akışının uygulamanızda nasıl ilerlediğini anlamayı zorlaştırır. [Alternatiflerden](#alternatives) birini denemeyi deneyin.
240
240
241
241
</Pitfall>
242
242
243
243
---
244
244
245
-
## Alternatives {/*alternatives*/}
245
+
## Alternatifler {/*alternatives*/}
246
246
247
-
### Passing data with a render prop {/*passing-data-with-a-render-prop*/}
247
+
### Render prop ile veri aktarımı {/*passing-data-with-a-render-prop*/}
248
248
249
-
Instead of using `cloneElement`, consider accepting a *render prop* like `renderItem`. Here,`List` receives `renderItem` as a prop. `List` calls `renderItem` for every item and passes `isHighlighted` as an argument:
249
+
`cloneElement` kullanmak yerine, `renderItem` gibi bir *render prop* kabul etmeyi düşünebilirsiniz. Burada`List`, `renderItem`’ı bir prop olarak alır. `List`, her item için `renderItem`’ı çağırır ve `isHighlighted`’ı bir argüman olarak geçirir:
The `renderItem` prop is called a "render prop" because it's a prop that specifies how to render something. For example, you can pass a `renderItem` implementation that renders a `<Row>`with the given `isHighlighted` value:
262
+
`renderItem` prop’una "render prop" denir çünkü bir şeyin nasıl render edileceğini belirten bir prop’tur. Örneğin, verilen `isHighlighted` değeri ile bir `<Row>`render eden bir `renderItem` implementasyonu geçebilirsiniz:
263
263
264
264
```js {3,7}
265
265
<List
@@ -274,7 +274,7 @@ The `renderItem` prop is called a "render prop" because it's a prop that specifi
274
274
/>
275
275
```
276
276
277
-
The end result is the same as with `cloneElement`:
277
+
Sonuç, `cloneElement` kullanımıyla elde edilen ile aynıdır:
278
278
279
279
```js {4,8,12}
280
280
<List>
@@ -293,7 +293,7 @@ The end result is the same as with `cloneElement`:
293
293
</List>
294
294
```
295
295
296
-
However, you can clearly trace where the `isHighlighted`value is coming from.
296
+
Ancak, `isHighlighted`değerinin nereden geldiğini açıkça takip edebilirsiniz.
297
297
298
298
<Sandpack>
299
299
@@ -389,7 +389,7 @@ button {
389
389
390
390
</Sandpack>
391
391
392
-
This pattern is preferred to `cloneElement` because it is more explicit.
392
+
Bu desen, `cloneElement`’e göre tercih edilir çünkü daha açıktır.
0 commit comments