Skip to content

docs(Tokenizer): the deprecated experimental.presentation names astryx upgrade - #9820

Closed
imdreamrunner wants to merge 1 commit into
mainfrom
fix/tokenizer-presentation-upgrade-command
Closed

imdreamrunner wants to merge 1 commit into
mainfrom
fix/tokenizer-presentation-upgrade-command

Conversation

@imdreamrunner

@imdreamrunner imdreamrunner commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Reader impact

A builder who still passes experimental={{presentation: x}} to Tokenizer reads the deprecation and learns the replacement, presentation, but not that astryx upgrade makes the change for them. After this PR, the deprecation note and the reference docs also name the migration command.

Source of truth

Correction

These places named only the replacement. They now say "Use the stable presentation prop; astryx upgrade rewrites static uses.":

  • the @deprecated JSDoc on TokenizerProps.experimental.presentation;
  • the experimental entries in Tokenizer.doc.mjs (English, Chinese and dense).

The development warning keeps its wording, "presentation wins. Remove experimental.presentation." It fires only when both spellings are set. The codemod leaves that case for a person, so the warning names the fix and not the command.

Evidence

git diff is 4 changed lines in Tokenizer.tsx and Tokenizer.doc.mjs, plus the Changeset.

Scope

  • This PR changes documentation only, or names every necessary generated artifact. api-report.md does not include JSDoc text, so it does not change.
  • Runtime, API, visual, and policy changes were removed or split.
  • Public text and artifacts contain no internal Meta context.

Testing

  • vitest: Tokenizer, 6 files and 205 tests, pass. Before that, Tokenizer, PowerSearch and the CLI golden reads passed: 20 files and 698 tests.
  • The @astryxdesign/core build passes, and tsc --noEmit passes for the package.
  • check:changesets, Changeset coverage (it ships to @astryxdesign/core, which the Changeset names) and check:knowledge pass. Prettier is clean.

@vercel

vercel Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 3, 2026 10:55pm UTC

Request Review

@astracat-bot

astracat-bot Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 3, 2026, 10:56 PM UTC

@imdreamrunner

Copy link
Copy Markdown
Contributor Author

/approve-spec 6440b7f

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 3, 2026

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Requesting changes. The @deprecated note and the three Tokenizer.doc.mjs entries are accurate, but the new sentence in the development warning points to a migration that does not apply where that warning fires.

  • The warning at Tokenizer.tsx:835 fires only when presentation and experimental.presentation are both set, and promote-tokenizer-presentation declines exactly that case (it leaves a TODO when both are attributes, and when presentation comes from an earlier spread it moves the experimental value after the spread, where the losing value starts to win), so please restore the previous message ("presentation wins. Remove experimental.presentation.") and drop the warning from the Changeset's list.

The codemod's own test for that shape (case c in promote-tokenizer-presentation.test.mjs) shows the behavior.

[Automated review]

useDevWarning(
'Tokenizer',
'`presentation` and `experimental.presentation` are both set; `presentation` wins. Remove `experimental.presentation`.',
'`presentation` and `experimental.presentation` are both set; `presentation` wins. Remove `experimental.presentation`. Use the stable `presentation` prop; `astryx upgrade` rewrites static uses.',

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This warning only fires when presentation and experimental.presentation are both set, and promote-tokenizer-presentation declines exactly that case: with both attributes it leaves a TODO (case c in its test), and with presentation from an earlier spread it moves the experimental value after the spread, so the losing value starts to win. Please keep the previous message here: `presentation` and `experimental.presentation` are both set; `presentation` wins. Remove `experimental.presentation`.

@imdreamrunner
imdreamrunner force-pushed the fix/tokenizer-presentation-upgrade-command branch from 6440b7f to e509abe Compare November 3, 2026 22:42
@imdreamrunner

Copy link
Copy Markdown
Contributor Author

/approve-spec e509abe

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

No changes needed. The @deprecated note on experimental.presentation and the three Tokenizer.doc.mjs entries now name astryx upgrade, which matches what the promote-tokenizer-presentation codemod does for a static experimental={{presentation: x}}. The both-set development warning keeps its earlier advice, so the concern raised on the previous revision is resolved. CI on this revision stopped because CI was at capacity rather than on a failing test, so it needs a re-run before merging.

[Automated review]

@imdreamrunner

Copy link
Copy Markdown
Contributor Author

Closing: the experimental presentation option is being removed rather than deprecated, so there is no deprecated spelling left to point at astryx upgrade. Tokenizer's stable presentation prop is the only spelling going forward.

@github-actions
github-actions Bot deleted the fix/tokenizer-presentation-upgrade-command branch November 4, 2026 06:04

This branch was successfully deployed

1 active deployment
Preview — e509abec Deployed Nov 3, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant