Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

Netail
Copy link
Member

@Netail Netail commented Oct 17, 2025

Summary

  • Stylelint does not apply to Json & Graphql, removed from description
  • css -> json in json description example
  • Align diagnostic naming across templates

Test Plan

Docs

@changeset-bot
Copy link

changeset-bot bot commented Oct 17, 2025

⚠️ No Changeset found

Latest commit: de582d2

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions github-actions bot added the A-Tooling Area: internal tools label Oct 17, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 17, 2025

Walkthrough

This pull request updates the code generation templates in xtask/codegen/src/generate_new_analyzer_rule.rs. The CSS, JSON, and GraphQL rule templates are revised to standardise diagnostic example documentation to JSON-style format and remove references to external stylelint rule links. The CSS template's diagnostic method signature is updated, changing parameter naming convention (_ to _ctx, node to state) and adjusting the diagnostic span source from node.range() to state.range(). Template documentation structure is simplified across all three language variants to focus on diagnostic examples only.

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed The PR description directly addresses the core changes made in the changeset. The summary section accurately lists the three main improvements: removing stylelint references from JSON and GraphQL templates, correcting the CSS-to-JSON label in the JSON example, and aligning diagnostic naming conventions. These points map clearly to the actual modifications described in the raw summary.
Title Check ✅ Passed The title "chore: improve rule templates" is directly related to the changeset. The PR makes improvements to the rule templates for CSS, JSON, and GraphQL by removing outdated Stylelint references, correcting examples, and aligning diagnostic naming conventions across templates. The title accurately captures the nature of the changes and would allow a teammate scanning history to understand this is a maintenance improvement to the code generation templates.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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

@Netail Netail changed the title chore: improve templates chore: improve rule templates Oct 17, 2025
Copy link
Contributor

@dyc3 dyc3 left a comment

Choose a reason for hiding this comment

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

Good catch. It's easy for these things to get stale.

Feel free to merge it yourself at your leisure. :)

@Netail Netail merged commit 9047c44 into biomejs:main Oct 17, 2025
13 checks passed
@Netail Netail deleted the chore/improve-templates branch October 17, 2025 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Tooling Area: internal tools

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants