-
Notifications
You must be signed in to change notification settings - Fork 99
Modules, introduction #106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @emadpoursina,
Please read the For New Translators
section there (#1):
The pull request title should be same as the article, e.g.
An Introduction to JavaScript
(just like comment)
Please make the requested changes. After it, add a comment "/done". |
/done |
## Build tools | ||
## ابزار های ساخت و ساز |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the English term after translating it!
### External scripts | ||
### اسکریپت های اکسترنال |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the English term after translating it!
Please make the requested changes. After it, add a comment "/done". |
/done |
- در اسکریپت های inline Async جواب می دهد. | ||
- برای بارگزاری اسکریپت های خارجی(external) از منابع دیگر (دامنه/پروتکل/پورت)، هدر های CORS نیاز هستند. | ||
- اسکریپت های مشابه external نادیده گرفته می شوند. | ||
2. ماژول های اسکوپ سطح بالای خود را دارند و از طریق عبارات `import/export` کارایی های خود را با دیگر اسکریپت های به اشتراک می گذارند. | ||
3. Modules always `use strict`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the English term after translating it!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry i will check whole translate again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It happens. :) Although I think this was the last one. 🤔
Please make the requested changes. After it, add a comment "/done". |
/done |
|
||
In the next chapter we'll see more examples of modules, and how things can be exported/imported. | ||
در فصل بعد ما مثال های بیشتری از ماژول ها را می بینیم، و اینکه چگونه آن ها صادر/وارد می شوند. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As you didn't translate import/export in other places, please don't translate it here as well.
</script> | ||
``` | ||
|
||
## Build tools | ||
## ابزار های ساخت و ساز |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ابزارهای ساخت
would be enough.
|
||
Build tools do the following: | ||
ابزارهای ساخت برای انجام کارهای زیر: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ابزارهای ساخت کارهای زیر را میکنند:
would be a better translation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will write;
ابزارهای ساخت کارهای زیر را انجام می دهند:
</script> | ||
``` | ||
|
||
### Module-level scope | ||
### اسکوپ های سطح ماژول |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
محدودهٔ/اسکوپ سطح ماژول
|
||
Let's say, a module exports an object: | ||
فرض می کنیم که یک ماژول یک آبجکت را صادر می کند: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use the term export
, صادرکردن
may cause misunderstanding.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should change all of he صادر to export or just this one??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we use export in persian, what do you think about using finglish: اکسپورت?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should i change وارد کردنs to import or just صادرs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mahdyar ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup, change both import and export.
And I think it'd be a good idea to change it everywhere else as well.
@@ -201,23 +201,23 @@ sayHi(); // Ready to serve, *!*Pete*/!*! | |||
|
|||
### import.meta |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Always translate the titles, since the translation will be in RTL, English doesn't look good that way.
You can use شی import.meta
</script> | ||
``` | ||
|
||
### In a module, "this" is undefined | ||
### در یک ماژول، "this" undefined است |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
تعریفنشده
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should change all of he undefined to تعریف نشده or just this one??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mahdyar ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just this one.
Please make the requested changes. After it, add a comment "/done". |
/done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @emadpoursina!
Thank you 💖 I updated the Progress Issue #1 🎉 🎉 🎉 |
No description provided.