Skip to content
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

Translate Suspense for Data Fetching #278

Merged
merged 6 commits into from
Dec 26, 2019
Merged

Conversation

smikitky
Copy link
Member

concurrent-mode-suspense.md の翻訳です

@netlify
Copy link

netlify bot commented Nov 26, 2019

Deploy preview for ja-reactjs ready!

Built with commit 8789bfe

https://deploy-preview-278--ja-reactjs.netlify.com

* データ取得の早期開始を明示するのが難しいことがある。ウォーターフォールを避けるため、そこを簡単にできるか?
* あるページのデータを取得する時に、そのページ*から*即座に遷移できるためのデータを含めるよう API が仕向けるべきか?
* レスポンスのライフタイムは? キャッシュはグローバル、あるいはローカルであるべきか? キャッシュをだれが管理するのか?
* Proxy を使うことで、あちこちに `read()` を挿入せずとも遅延ロード API を表現することが可能か?
Copy link
Member Author

Choose a reason for hiding this comment

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

ここでの Proxy がどういうものなのか分かっていませんがとりあえずそのままにしてあります

Copy link
Member

Choose a reason for hiding this comment

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

ES2015のProxyを指しているのかなと思いました。そのままでよさそうです。


This code is deceptively easy to read.
これは見かけほど簡単ではありません。
Copy link
Member Author

@smikitky smikitky Nov 26, 2019

Choose a reason for hiding this comment

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

普通に英語として意味がピンときていません…

辺りを総合すると、ネイティブスピーカーでも意見が分かれる(通常は避けるべき)表現であり、

  1. 見かけは簡単だが実際は難しい
  2. 見かけが難しいだけで実際は簡単だ

のどちらの意味にもとれるそうなのですが、今回はどちらの解釈も文脈にあまり合致しない気がします(どう見てもクラスの方が関数コンポーネントより煩雑ですから1は妙だし、2のようにクラスコンポーネントを急に褒め出すのも違和感があります)。

もうちょっと皮肉っぽいニュアンスで「簡単という人もいそうですが決してそんなわけないですよね」あるいは「思ってたより簡単(笑)でしたね」みたいな話なら分かる気もしますが、当てずっぽうです。

Copy link
Member

Choose a reason for hiding this comment

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

難しいですね...。個人的には2なのかなと思いました。
クラスコンポーネントの場合、コードが増えて複雑に見えるけど、やっていることは単純だという。
ただ、あまり自信はないです。

Copy link
Member Author

Choose a reason for hiding this comment

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

確かに2の方向でも通じる気がしてきたのでそのようにします!

1. ユーザ詳細情報の取得を開始
2. 待機する…
3. ユーザ詳細情報の取得が完了
4. タイムライン投稿 (posts) の取得を開始
Copy link
Member Author

Choose a reason for hiding this comment

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

読みやすさのため一部の「投稿」を「タイムライン投稿」としました(以下同様)。

@koba04 koba04 self-assigned this Dec 3, 2019
Copy link
Member

@koba04 koba04 left a comment

Choose a reason for hiding this comment

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

👍 翻訳ありがとうございます!!! いくつかコメントしましたので確認お願いします!

content/docs/concurrent-mode-suspense.md Outdated Show resolved Hide resolved
* データ取得の早期開始を明示するのが難しいことがある。ウォーターフォールを避けるため、そこを簡単にできるか?
* あるページのデータを取得する時に、そのページ*から*即座に遷移できるためのデータを含めるよう API が仕向けるべきか?
* レスポンスのライフタイムは? キャッシュはグローバル、あるいはローカルであるべきか? キャッシュをだれが管理するのか?
* Proxy を使うことで、あちこちに `read()` を挿入せずとも遅延ロード API を表現することが可能か?
Copy link
Member

Choose a reason for hiding this comment

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

ES2015のProxyを指しているのかなと思いました。そのままでよさそうです。

content/docs/concurrent-mode-suspense.md Outdated Show resolved Hide resolved

This code is deceptively easy to read.
これは見かけほど簡単ではありません。
Copy link
Member

Choose a reason for hiding this comment

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

難しいですね...。個人的には2なのかなと思いました。
クラスコンポーネントの場合、コードが増えて複雑に見えるけど、やっていることは単純だという。
ただ、あまり自信はないです。

@koba04 koba04 removed their assignment Dec 8, 2019
@smikitky smikitky requested a review from koba04 December 11, 2019 04:55
Copy link
Member

@koba04 koba04 left a comment

Choose a reason for hiding this comment

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

👍 対応ありがとうございます!!!

@smikitky smikitky merged commit 0a9573a into master Dec 26, 2019
@smikitky smikitky deleted the tr/concurrent-suspense branch December 26, 2019 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants