Add 'Choosing the right method' quick-reference to Overview pages#243
Open
moss-bryophyta wants to merge 1 commit intomainfrom
Open
Add 'Choosing the right method' quick-reference to Overview pages#243moss-bryophyta wants to merge 1 commit intomainfrom
moss-bryophyta wants to merge 1 commit intomainfrom
Conversation
Add a decision table to the SDK Overview pages (both the docs-template and the Next.js-specific introduction) that helps developers quickly identify which translation method to use for their use case. This is the most common question developers have when they land on the Overview page and see 5+ different APIs. The table maps concrete use cases (JSX content, HTML attributes, config objects, server components, migrations) to the recommended method, with a callout reinforcing that <T> is the default choice.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a "Choosing the right method" decision table to the SDK Overview pages — the most important docs pages after the Quickstart.
Why
The Overview page introduces 5–6 different translation APIs (
<T>,useGT,msg,useTranslations,getGT,withGTConfig). Developers landing here need to quickly understand which method fits their use case — but currently they have to read through every section to figure it out.This table gives them the answer at a glance:
<T>placeholder,aria-label,alt)useGTmsg+useMessagesgetGTuseTranslationsPlus a callout reinforcing that
<T>is the default choice when in doubt.Scope
docs-templates/introduction.mdx— the shared template (generates React Overview and others)docs/en-US/next/introduction.mdx— the Next.js-specific Overview (includesgetGTfor server components)