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/Children.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
@@ -141,7 +141,7 @@ Otherwise, returns a flat array consisting of the nodes you've returned from the
141
141
### `Children.only(children)` {/*children-only*/}
142
142
143
143
144
-
Call `Children.only(children)`to assert that `children` represent a single React element.
144
+
Alt elemanların tek bir React öğesini temsil ettiğini doğrulamak için `Children.only(children)`öğesini çağırın.
145
145
146
146
```js
147
147
functionBox({ children }) {
@@ -155,13 +155,13 @@ function Box({ children }) {
155
155
156
156
#### Returns {/*children-only-returns*/}
157
157
158
-
If`children` [is a valid element,](/reference/react/isValidElement) returns that element.
158
+
Eğer`children` [geçerli bir eleman ise,](/reference/react/isValidElement) bu elemanı döndürür.
159
159
160
-
Otherwise, throws an error.
160
+
Aksi takdirde hata verir.
161
161
162
-
#### Caveats {/*children-only-caveats*/}
162
+
#### Uyarılar {/*children-only-caveats*/}
163
163
164
-
- This method always **throws if you pass an array (such as the return value of `Children.map`) as `children`.** In other words, it enforces that `children` is a single React element, not that it's an array with a single element.
164
+
- Bu yöntem **`children` olarak bir dizi (örneğin, `Children.map`'in dönüş değeri) geçirirseniz her zaman hata fırlatır.** Başka bir deyişle, `children`'ın tek bir React öğesi olmasını zorunlu kılar, ancak bu bir öğe içeren bir dizi olması anlamına gelmez.
165
165
166
166
---
167
167
@@ -188,15 +188,15 @@ export default function ReversedList({ children }) {
188
188
189
189
#### Uyarılar {/*children-toarray-caveats*/}
190
190
191
-
- Empty nodes (`null`, `undefined`, and Booleans) will be omitted in the returned array. **The returned elements' keys will be calculated from the original elements' keys and their level of nesting and position.** This ensures that flattening the array does not introduce changes in behavior.
191
+
- Boş node'lar (`null`, `undefined` ve Booleans) döndürülen dizide atlanacaktır. **Döndürülen öğelerin anahtarları, orijinal öğelerin anahtarlarından, iç içe geçme düzeylerinden ve konumlarından hesaplanacaktır.** Bu, dizinin düzleştirilmesinin davranışta değişikliklere yol açmamasını sağlar.
192
192
193
193
---
194
194
195
-
## Usage {/*usage*/}
195
+
## Kullanım {/*usage*/}
196
196
197
-
### Transforming children {/*transforming-children*/}
To transform the children JSX that your component [receives as the `children` prop,](/learn/passing-props-to-a-component#passing-jsx-as-children) call `Children.map`:
@@ -214,7 +214,7 @@ function RowList({ children }) {
214
214
}
215
215
```
216
216
217
-
In the example above, the `RowList`wraps every child it receives into a `<div className="Row">`container. For example, let's say the parent component passes three `<p>` tags as the `children` prop to `RowList`:
217
+
Yukarıdaki örnekte, `RowList`aldığı her children'ı bir `<div className=“Row”>` konteynerine sarar. Örneğin, ana bileşenin `RowList` öğesine `children` prop'u olarak üç `<p>` etiketi ilettiğini varsayalım:
0 commit comments