Skip to content

docs: biome node field names example#4129

Open
dyc3 wants to merge 1 commit intomainfrom
dyc3/grit-native-node-field-names-docs
Open

docs: biome node field names example#4129
dyc3 wants to merge 1 commit intomainfrom
dyc3/grit-native-node-field-names-docs

Conversation

@dyc3
Copy link
Copy Markdown
Contributor

@dyc3 dyc3 commented Apr 6, 2026

Summary

Docs for biomejs/biome#9739

This feels a bit too small, but honestly can't think of what else to put.

@netlify
Copy link
Copy Markdown

netlify bot commented Apr 6, 2026

Deploy Preview for biomejs ready!

Name Link
🔨 Latest commit e2617bf
🔍 Latest deploy log https://app.netlify.com/projects/biomejs/deploys/69d3d5158d55f30009c8158f
😎 Deploy Preview https://deploy-preview-4129--biomejs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 6, 2026

Lunaria Status Overview

🌕 This pull request will trigger status changes.

Learn more

By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.

You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

Locale File Note
en src/content/docs/reference/gritql.mdx Source changed, localizations will be marked as outdated.
Warnings reference
Icon Description
🔄️ The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 6, 2026

Walkthrough

The GritQL documentation is updated with a practical example demonstrating how to match specific portions of Biome syntax nodes using field names (e.g., JsConditionalExpression(consequent = $cons)). The changes refine the distinction between discovering node names alone versus discovering both node names and field names, and clarify that breaking changes may impact patterns relying on node or field name matching. This is documentation-only with no modifications to exported code entities.

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: adding documentation about Biome node field names with an example.
Description check ✅ Passed The description is related to the changeset, explaining it documents changes from a Biome PR, though it's minimal and acknowledges its own brevity.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dyc3/grit-native-node-field-names-docs

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/content/docs/reference/gritql.mdx`:
- Line 139: The sentence "This may cause node names to change, which could break
your patterns. Be prepared to update your queries when upgrading Biome when
using node/field names in your patterns." is wordy and repeats "when"; replace
it with a single clearer sentence such as: "Because Biome's grammar can change
between versions (especially for new languages), node and field names may
change, so be prepared to update any patterns that depend on them when you
upgrade." Locate the original sentence in the documentation (the paragraph that
begins "Biome's grammar can change between versions...") and substitute this
streamlined version to improve readability.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5122e3de-ec45-4970-9486-2da0c1ac6d00

📥 Commits

Reviewing files that changed from the base of the PR and between 7f16577 and e2617bf.

📒 Files selected for processing (1)
  • src/content/docs/reference/gritql.mdx


:::caution
Biome's grammar can change between versions, especially for new languages. This may cause node names to change, which could break your patterns. Be prepared to update your queries when upgrading Biome.
Biome's grammar can change between versions, especially for new languages. This may cause node names to change, which could break your patterns. Be prepared to update your queries when upgrading Biome when using node/field names in your patterns.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Tiny wording polish for readability.

Line 139 reads a bit repetitive (“when ... when ...”). A small rewrite would scan better for readers.

✍️ Suggested edit
-Biome's grammar can change between versions, especially for new languages. This may cause node names to change, which could break your patterns. Be prepared to update your queries when upgrading Biome when using node/field names in your patterns.
+Biome's grammar can change between versions, especially for new languages. This may cause node or field names to change, which could break your patterns. If your queries rely on node/field names, be prepared to update them when upgrading Biome.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Biome's grammar can change between versions, especially for new languages. This may cause node names to change, which could break your patterns. Be prepared to update your queries when upgrading Biome when using node/field names in your patterns.
Biome's grammar can change between versions, especially for new languages. This may cause node or field names to change, which could break your patterns. If your queries rely on node/field names, be prepared to update them when upgrading Biome.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/content/docs/reference/gritql.mdx` at line 139, The sentence "This may
cause node names to change, which could break your patterns. Be prepared to
update your queries when upgrading Biome when using node/field names in your
patterns." is wordy and repeats "when"; replace it with a single clearer
sentence such as: "Because Biome's grammar can change between versions
(especially for new languages), node and field names may change, so be prepared
to update any patterns that depend on them when you upgrade." Locate the
original sentence in the documentation (the paragraph that begins "Biome's
grammar can change between versions...") and substitute this streamlined version
to improve readability.

@ematipico
Copy link
Copy Markdown
Member

ematipico commented Apr 8, 2026

@dyc3

We should update https://biomejs.dev/recipes/gritql-plugins/ with one/two examples of what we can do now.

@ematipico ematipico added the Merge on release PRs that should be merged once the next minor in core is released label Apr 8, 2026
@dyc3 dyc3 mentioned this pull request Apr 8, 2026
@dyc3
Copy link
Copy Markdown
Contributor Author

dyc3 commented Apr 8, 2026

I'm having a hard time coming up with anything that would be useful. I'll revisit it later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Documentation Merge on release PRs that should be merged once the next minor in core is released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants