Skip to content
This repository was archived by the owner on Jan 20, 2025. It is now read-only.

Conversation

@nakajmg
Copy link
Contributor

@nakajmg nakajmg commented Jan 16, 2020

レビューお願いします 🙏

If you're not familiar with static queries in Gatsby, you might want to check out the difference between a static query and a page query.

ここに出てくる static query を静的クエリと訳しましたが、リンク( https://www.gatsbyjs.org/docs/static-query/#how-staticquery-differs-from-page-query ) の内容的には StaticQuery の話なので、ここはどう訳すのがベターそうでしょうか?

@smorimoto smorimoto added the status: awaiting review A pull request that is currently awaiting a reviewer's response label Jan 16, 2020
Copy link
Contributor

@uetchy uetchy left a comment

Choose a reason for hiding this comment

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

ありがとうございます👍


- `useStaticQuery` does not accept variables (hence the name "static"), but can be used in _any_ component, including pages
- Because of how queries currently work in Gatsby, we support only a single instance of `useStaticQuery` in a file
- `useStaticQuery` は値を受け取れません(なので `static` という名前になっています)。しかし、ページを含む*どのような*コンポーネントでも使えます。
Copy link
Contributor

Choose a reason for hiding this comment

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

日本語の斜体はあまり強調されず、わかりにくいので**2個使って太字にしましょう。

@uetchy uetchy added the status: awaiting author response A pull request that is awaiting author's response label Jan 16, 2020
@nakajmg nakajmg requested a review from smorimoto as a code owner January 16, 2020 16:54
@nakajmg nakajmg requested a review from uetchy January 16, 2020 16:58
@nakajmg
Copy link
Contributor Author

nakajmg commented Jan 16, 2020

#43 (comment)

*** に変更しました

3eb17dd

uetchy
uetchy previously approved these changes Jan 16, 2020
@uetchy uetchy added status: awaiting more approval A pull request that is awaiting reviewer #2 to be assigned and removed status: awaiting author response A pull request that is awaiting author's response status: awaiting review A pull request that is currently awaiting a reviewer's response labels Jan 16, 2020
@nakajmg
Copy link
Contributor Author

nakajmg commented Jan 17, 2020

スタイルガイド#用語集Query を見落としていました。

クエリクエリー に変更しました。

uetchy
uetchy previously approved these changes Jan 17, 2020
Copy link
Contributor

@uetchy uetchy left a comment

Choose a reason for hiding this comment

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

🚀

Copy link
Contributor

@hirotaka hirotaka left a comment

Choose a reason for hiding this comment

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

ありがとうございます!一つだけコメントさせていただいたので確認お願いします。

Gatsby v2.1.0 `useStaticQuery` が導入されました。これはビルド時に [React Hook](https://reactjs.org/docs/hooks-intro.html) を使って GraphQL のクエリーを実行する新しい機能です。

Just like the [StaticQuery](/docs/static-query/) component, it allows your React components to retrieve data via a GraphQL query that will be parsed, evaluated, and injected into the component. However, `useStaticQuery` is a hook rather than a component that takes a render prop!
React コンポーネントで、 [StaticQuery](/docs/static-query/) コンポーネントと同じように GraphQL クエリーを介したデータの取得とコンポーネントへの注入を行えます。
Copy link
Contributor

Choose a reason for hiding this comment

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

However, useStaticQuery is a hook rather than a component that takes a render prop!

この文の訳が見当たらないようなのですが、意図しているものでしたでしょうか。

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
Contributor Author

Choose a reason for hiding this comment

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

89a27c7

追加しました

Copy link
Contributor Author

Choose a reason for hiding this comment

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

a component that takes a render prop!

ここの訳が少し自信ないです。

レンダープロップを受け取るコンポーネント

としましたが、 受け取る ではなくて 取る のほうが意味的には合ってそうでしょうか?

レンダープロップ については公式のドキュメントにレンダープロップの項があったのでそれに倣っています。

Copy link
Contributor

Choose a reason for hiding this comment

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

レンダープロップ でよさそうです。

レンダープロップを受け取るコンポーネント

に関しては、suggetionをあげさせていただいたのでご確認お願いいたいします。

@hirotaka hirotaka added the status: awaiting author response A pull request that is awaiting author's response label Jan 18, 2020
Copy link
Contributor

@hirotaka hirotaka left a comment

Choose a reason for hiding this comment

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

確かに、悩ましいですね。

Co-Authored-By: Hirotaka Mizutani <[email protected]>
@nakajmg nakajmg requested a review from hirotaka January 20, 2020 00:56
Copy link
Contributor

@hirotaka hirotaka left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@hirotaka hirotaka requested a review from uetchy January 20, 2020 02:45
@uetchy uetchy merged commit dbc4060 into gatsbyjs:master Jan 20, 2020
@gatsbot
Copy link

gatsbot bot commented Jan 20, 2020

Holy buckets, @nakajmg — we just merged your PR to Gatsby! 💪💜

Gatsby is built by awesome people like you. Let us say “thanks” in two ways:

  1. We’d like to send you some Gatsby swag. As a token of our appreciation, you can go to the Gatsby Swag Store and log in with your GitHub account to get a coupon code good for one free piece of swag. We’ve got Gatsby t-shirts, stickers, hats, scrunchies, and much more. (You can also unlock even more free swag with 5 contributions — wink wink nudge nudge.) See gatsby.dev/swag for details.
  2. We just invited you to join the Gatsby organization on GitHub. This will add you to our team of maintainers. Accept the invite by visiting https://github.com/orgs/gatsbyjs/invitation. By joining the team, you’ll be able to label issues, review pull requests, and merge approved pull requests.

If there’s anything we can do to help, please don’t hesitate to reach out to us: tweet at @gatsbyjs and we’ll come a-runnin’.

Thanks again!

@uetchy uetchy removed status: awaiting author response A pull request that is awaiting author's response status: awaiting more approval A pull request that is awaiting reviewer #2 to be assigned labels Jan 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants