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: 1-js/13-modules/02-import-export/article.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -228,19 +228,19 @@ export class { // Hata! (non-default export needs a name)
228
228
229
229
### "Default" Takma Adı
230
230
231
-
The "default" keyword is used as an "alias" for the default export, for standalone exports and other scenarios when we need to reference it.
231
+
"defaul" anahtar sözcüğü, varsayılan içeriye aktarma, bağımsız içeriye aktarma ve referans göstermemiz gerektiğinde diğer seneryolar için "takma ad" kullanılır
232
232
233
-
For example, if we already have a function declared, that's how to `export default`it (separately from the definition):
233
+
Örneğin, önceden bildirilmiş bir işlevimiz varsa , işte bunu `export default` nasıl yaparız (tanımdan ayrı olarak):
234
234
235
235
```js
236
236
function sayHi(user) {
237
237
alert(`Hello, ${user}!`);
238
238
}
239
239
240
-
export {sayHi as default}; // same as if we added "export default" before the function
240
+
export {sayHi as default}; // fonksiyondan önce "export default" eklediğimiz gibi
241
241
```
242
242
243
-
Or, let's say a module `user.js` exports one main "default" thing and a few named ones (rarely the case, but happens):
243
+
Ya da bir `user.js` modulünün bir ana "varsayılan" şeyi ve bir kaç tane adlandırılmış olanı dışarı aktarıldığını varsayalım.
244
244
245
245
```js
246
246
// 📁 user.js
@@ -255,7 +255,7 @@ export function sayHi(user) {
255
255
}
256
256
```
257
257
258
-
Here's how to import the default export along with a named one:
258
+
Varsayılan dışa aktarma adını adlandırılmış olanla birlikte şu şekilde alabiliriz:
259
259
260
260
```js
261
261
// 📁 main.js
@@ -264,7 +264,7 @@ import {*!*default as User*/!*, sayHi} from './user.js';
264
264
new User('John');
265
265
```
266
266
267
-
Or, if we consider importing `*`as an object, then the `default`property is exactly the default export:
267
+
Ya da `*` nesnesini almayı düşünürsek `default` özelliği tam olarak varsayılan içeriye aktarmadır:
0 commit comments