-
Notifications
You must be signed in to change notification settings - Fork 57
Translate faq-structure.md #44
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
content/docs/faq-structure.md
Outdated
|
||
#### Avoid too much nesting {#avoid-too-much-nesting} | ||
#### הימנע מיותר מדי nesting {#avoid-too-much-nesting} |
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 is a Hebrew word for nesting, it's קינון. I think you can change the sentence to:
הימנע מיותר מידי קינון
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.
Maybe המנע מעודף קינון?
|
||
#### Grouping by features or routes {#grouping-by-features-or-routes} | ||
#### קיבוץ לפי פיצ'רים או routes {#grouping-by-features-or-routes} |
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.
Routes can be נתיבים.
@@ -35,11 +35,11 @@ profile/ | |||
ProfileAPI.js | |||
``` | |||
|
|||
The definition of a "feature" is not universal, and it is up to you to choose the granularity. If you can't come up with a list of top-level folders, you can ask the users of your product what major parts it consists of, and use their mental model as a blueprint. |
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.
You can change top-level folders to תיקיות ברמה עליונה. Tell me what do you think about it?
|
||
There are many pain points associated with deep directory nesting in JavaScript projects. It becomes harder to write relative imports between them, or to update those imports when the files are moved. Unless you have a very compelling reason to use a deep folder structure, consider limiting yourself to a maximum of three or four nested folders within a single project. Of course, this is only a recommendation, and it may not be relevant to your project. |
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.
What do you think of ייבוא יחסי as a translated word for relative imports?
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.
Not sure about that, I think it might create more confusion
content/docs/faq-structure.md
Outdated
|
||
If you're just starting a project, [don't spend more than five minutes](https://en.wikipedia.org/wiki/Analysis_paralysis) on choosing a file structure. Pick any of the above approaches (or come up with your own) and start writing code! You'll likely want to rethink it anyway after you've written some real code. | ||
אם אתה רק מתחיל פרויקט, [אל תבזבז יותר מחמש דקות](https://en.wikipedia.org/wiki/Analysis_paralysis) אם אתה רק מתחיל פרויקט, אל תבזבז יותר מחמש דקות על בחירת מבנה הפרויקט. בחר אחת מהגישות שלמעלה(או שתחשוב על אחת משלך) ותתחיל לכתוב קוד! אתה כנראה תרצה לחשוב על זה מחדש אחרי שתכתוב קוד אמיתי. |
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.
You repeated אם אתה רק מתחיל פרויקט, אל תבזבז יותר מחמש דקות
content/docs/faq-structure.md
Outdated
|
||
#### Grouping by features or routes {#grouping-by-features-or-routes} | ||
#### קיבוץ לפי תכונות או routes {#grouping-by-features-or-routes} |
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 would use פיצ'ר instead of תכונות in this context
content/docs/faq-structure.md
Outdated
|
||
If you feel completely stuck, start by keeping all files in a single folder. Eventually it will grow large enough that you will want to separate some files from the rest. By that time you'll have enough knowledge to tell which files you edit together most often. In general, it is a good idea to keep files that often change together close to each other. This principle is called "colocation". | ||
אם אתה מרגיש תקוע לגמרי, תתחיל בלהשאיר את כל הקבצים בתיקייה אחת. בסופו של דבר היא תגדל מספיק עד שתרגיש את הצורך להפריד כמה קבצים מהתיקייה. בעת ההיא יהיה לך מספיק ידע על אילו קבצים אתה עורך בתדירות הכי גבוהה. באופן כללי, זה רעיון טוב להשאיר קבצים שמשתנים בתדירות גבוהה קרובים אחד לשני. עיקרון זה נקרא ''קולוקציה''. |
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.
''
-> "
content/docs/faq-structure.md
Outdated
|
||
As projects grow larger, they often use a mix of both of the above approaches in practice. So choosing the "right" one in the beginning isn't very important. | ||
כשפרויקטים גדלים, רוב הזמן הם משלבים את שתי הגישות שהראנו מקודם. מכאן נובע שבחירת הגישה ה''נכונה'' בתחילת הפרויקט היא לא חשובה. |
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.
''
-> "
content/docs/faq-structure.md
Outdated
|
||
One common way to structure projects is locate CSS, JS, and tests together inside folders grouped by feature or route. | ||
דרך נפוצה אחת בבניית פרויקטים היא לקבץ קבצי CSS, JS ובדיקות ביחד בתוך תיקיות לפי תכונות או routes. |
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.
Same for תכונות as above
content/docs/faq-structure.md
Outdated
|
||
There are many pain points associated with deep directory nesting in JavaScript projects. It becomes harder to write relative imports between them, or to update those imports when the files are moved. Unless you have a very compelling reason to use a deep folder structure, consider limiting yourself to a maximum of three or four nested folders within a single project. Of course, this is only a recommendation, and it may not be relevant to your project. | ||
ישנם כמה בעיות שקשורות עם nesting עמוק בפרויקטי JavaScript. זה נהיה קשה לכתוב relative imports ביניהם, או לעדכן את ה imports הללו כשהקבצים זזים. אלא אם יש לך סיבה מוצדקת להשתמש במבנה תיקיות עמוק, עדיף שיהיה עומק של מקסימום שלוש או ארבע תיקיות בפרויקט אחד. עם זאת, זוהי רק המלצה, ויכול להיות שהיא לא רלוונטית לפרויקט שלך. |
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.
ישנם -> ישנן
עם nesting -> בקינון
זה נהיה קשה -> נהיה קשה יותר (remove זה)
I wouldn't change imports, as it is refering the keyword
content/docs/faq-structure.md
Outdated
|
||
#### Don't overthink it {#dont-overthink-it} | ||
#### אין צורך להשקיע מחשבה רבה בנושא {#dont-overthink-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.
Maybe instead of רבה use מיותרת?
Deploy preview for he-reactjs failed. Built with commit cb16b36 https://app.netlify.com/sites/he-reactjs/deploys/5c89748ff070ee00083d70f4 |
No description provided.