Skip to content

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

Merged
merged 4 commits into from
Apr 9, 2021
Merged

Conversation

emadpoursina
Copy link
Contributor

No description provided.

Copy link
Member

@mahdyar mahdyar left a 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)

@javascript-translate-bot

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

@emadpoursina emadpoursina changed the title translate article.md Modules, introduction Apr 6, 2021
@emadpoursina
Copy link
Contributor Author

/done

Comment on lines 347 to 348
## Build tools
## ابزار های ساخت و ساز
Copy link
Member

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!

Comment on lines 299 to 300
### External scripts
### اسکریپت های اکسترنال
Copy link
Member

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!

@javascript-translate-bot

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

@emadpoursina
Copy link
Contributor Author

/done

- در اسکریپت های inline Async جواب می دهد.
- برای بارگزاری اسکریپت های خارجی(external) از منابع دیگر (دامنه/پروتکل/پورت)، هدر های CORS نیاز هستند.
- اسکریپت های مشابه external نادیده گرفته می شوند.
2. ماژول های اسکوپ سطح بالای خود را دارند و از طریق عبارات ‍`import/export` کارایی های خود را با دیگر اسکریپت های به اشتراک می گذارند.
3. Modules always `use strict`.
Copy link
Member

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!

Copy link
Contributor Author

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.

Copy link
Member

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. 🤔

@javascript-translate-bot

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

@emadpoursina
Copy link
Contributor Author

/done


In the next chapter we'll see more examples of modules, and how things can be exported/imported.
در فصل بعد ما مثال های بیشتری از ماژول ها را می بینیم، و اینکه چگونه آن ها صادر/وارد می شوند.
Copy link
Member

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
## ابزار های ساخت و ساز
Copy link
Member

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:
ابزارهای ساخت برای انجام کارهای زیر:
Copy link
Member

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.

Copy link
Contributor Author

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
### اسکوپ های سطح ماژول
Copy link
Member

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:
فرض می کنیم که یک ماژول یک آبجکت را صادر می کند:
Copy link
Member

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.

Copy link
Contributor Author

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??

Copy link
Contributor Author

@emadpoursina emadpoursina Apr 7, 2021

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: اکسپورت?

Copy link
Contributor Author

@emadpoursina emadpoursina Apr 7, 2021

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?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

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
Copy link
Member

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 است
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

تعریف‌نشده

Copy link
Contributor Author

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??

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just this one.

@javascript-translate-bot

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

@emadpoursina
Copy link
Contributor Author

/done

Copy link
Member

@mahdyar mahdyar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @emadpoursina!

@javascript-translate-bot

Thank you 💖 I updated the Progress Issue #1 🎉 🎉 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants