Skip to content

refactor(formatter): clarify jsdoc embedded formatting#23807

Merged
graphite-app[bot] merged 1 commit into
mainfrom
06-26-refactor_formatter_clarify_jsdoc_embedded_formatting
Jun 29, 2026
Merged

refactor(formatter): clarify jsdoc embedded formatting#23807
graphite-app[bot] merged 1 commit into
mainfrom
06-26-refactor_formatter_clarify_jsdoc_embedded_formatting

Conversation

@leaysgur

@leaysgur leaysgur commented Jun 26, 2026

Copy link
Copy Markdown
Member

It might not be widely known, but you can embed multiple languages within JSDoc(Markdown code fence, @example tag), and those will be formatted as well.

However, because it works a bit differently from other embedded formattings and can be confusing, I will clarify how it works here.

leaysgur commented Jun 26, 2026

Copy link
Copy Markdown
Member Author

How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent changes, fast-track this PR to the front of the merge queue

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@codspeed-hq

codspeed-hq Bot commented Jun 26, 2026

Copy link
Copy Markdown

Merging this PR will improve performance by 4.55%

⚠️ Different runtime environments detected

Some benchmarks with significant performance changes were compared across different runtime environments,
which may affect the accuracy of the results.

Open the report in CodSpeed to investigate

⚡ 6 improved benchmarks
✅ 46 untouched benchmarks
⏩ 19 skipped benchmarks1

Performance Changes

Mode Benchmark BASE HEAD Efficiency
Simulation formatter[errors.ts] 616.6 µs 574.1 µs +7.4%
Simulation isolated-declarations[vue-id.ts] 52.8 ms 49.7 ms +6.28%
Simulation formatter[handle-comments.js] 2.9 ms 2.8 ms +4.09%
Simulation formatter[index.tsx] 3.9 ms 3.8 ms +3.59%
Simulation formatter[next.ts] 2.4 ms 2.3 ms +3.02%
Simulation formatter[core.js] 1.6 ms 1.6 ms +3.02%

Tip

Curious why this is faster? Comment @codspeedbot explain why this is faster on this PR, or directly use the CodSpeed MCP with your agent.


Comparing 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting (e2b6b3b) with 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js (10c88b1)2

Open in CodSpeed

Footnotes

  1. 19 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

  2. No successful run was found on 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js (edbb9ee) during the generation of this report, so 0cf3f5d was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@leaysgur leaysgur force-pushed the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch from 60bf9fe to d3f3837 Compare June 29, 2026 02:32
@leaysgur leaysgur force-pushed the 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js branch from 10c88b1 to dea8a75 Compare June 29, 2026 02:33
@graphite-app graphite-app Bot added the 0-merge Merge with Graphite Merge Queue label Jun 29, 2026
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js branch from bf01e94 to 1c3294d Compare June 29, 2026 03:09
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch from fa23271 to 859924f Compare June 29, 2026 03:10
@graphite-app

graphite-app Bot commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Merge activity

@graphite-app graphite-app Bot removed the 0-merge Merge with Graphite Merge Queue label Jun 29, 2026
@leaysgur leaysgur force-pushed the 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js branch from 1c3294d to edbb9ee Compare June 29, 2026 03:48
@leaysgur leaysgur force-pushed the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch from 859924f to e2b6b3b Compare June 29, 2026 03:48
@graphite-app graphite-app Bot added the 0-merge Merge with Graphite Merge Queue label Jun 29, 2026
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js branch 2 times, most recently from 480b500 to f90838c Compare June 29, 2026 03:59
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch from e2b6b3b to 86adbd1 Compare June 29, 2026 03:59
It might not be widely known, but you can embed multiple languages within JSDoc(Markdown code fence, `@example` tag), and those will be formatted as well.

However, because it works a bit differently from other embedded formattings and can be confusing, I will clarify how it works here.
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js branch from f90838c to 4e2a194 Compare June 29, 2026 04:06
@graphite-app graphite-app Bot force-pushed the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch from 86adbd1 to 96b48a3 Compare June 29, 2026 04:07
Base automatically changed from 06-26-refactor_oxfmt_formatter_move_gql-in-js_escape_logic_to_formatter_js to main June 29, 2026 04:11
@graphite-app graphite-app Bot removed the 0-merge Merge with Graphite Merge Queue label Jun 29, 2026
@graphite-app graphite-app Bot merged commit 96b48a3 into main Jun 29, 2026
31 checks passed
@graphite-app graphite-app Bot deleted the 06-26-refactor_formatter_clarify_jsdoc_embedded_formatting branch June 29, 2026 04:13
camc314 pushed a commit that referenced this pull request Jul 3, 2026
It might not be widely known, but you can embed multiple languages within JSDoc(Markdown code fence, `@example` tag), and those will be formatted as well.

However, because it works a bit differently from other embedded formattings and can be confusing, I will clarify how it works here.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-formatter Area - Formatter

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant