diagnostics-development
Build effective error messages, warnings, and hints for Biome lint rules using the Diagnostic trait and advice system. Learn to craft messages that explain what went wrong, why it matters, and how to fix it—with rich markup, code frames, and actionable guidance.
diagnostics-development helps you create clear, actionable error messages and warnings for Biome lint rules.
AI-generated summary based on this skill's SKILL.md
Decision gist · record as of 2026-07-27
diagnostics-development helps you create clear, actionable error messages and warnings for Biome lint rules. Build effective error messages, warnings, and hints for Biome lint rules using the Diagnostic trait and advice system. Learn to craft messages that explain what went wrong, why it matters, and how to fix it—with rich markup, code frames, and actionable guidance.
Use it when
- diagnostics-development explains that Biome advice types let you attach actionable guidance to diagnostics.
- diagnostics-development emphasizes building user-friendly messages by explaining the problem clearly, showing why it matters.
Verify before relying
Read SKILL.md below before installing (1 file). Open directory: indexed for reading, not audited.
Install
biomejs/biome/diagnostics-development · repository language: Rust
Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.
Frequently asked questions
AI-generated answers based on this skill's SKILL.md and metadata
How to create diagnostics in Biome?
diagnostics-development teaches you to build error messages for Biome lint rules using the Diagnostic trait and RuleDiagnostic builder. Start by deriving the Diagnostic trait on your error type, then use RuleDiagnostic to construct messages with advice, code frames, and markup. The skill covers registering diagnostic categories, configuring severity levels, and applying show-don't-tell philosophy so users understand what went wrong, why it matters, and how to fix it.
What are Biome advice types and how do I use code frame diffs?
diagnostics-development explains that Biome advice types let you attach actionable guidance to diagnostics. Code frame diffs show before-and-after code snippets, helping users visualize fixes. The skill teaches markup formatting for emphasis and clarity, multi-advice diagnostics for complex issues, and how to tag diagnostics as fixable. Together, these create high-quality diagnostic output that guides developers toward resolution.
How do I write lint rule error messages that are user-friendly?
diagnostics-development emphasizes building user-friendly messages by explaining the problem clearly, showing why it matters, and providing concrete next steps. Use markup formatting for readability, include code frames to contextualize errors, and apply the show-don't-tell principle—let the code and diffs speak rather than abstract language. The skill covers best practices for actionable error messages that help developers fix issues quickly.
What is the RuleDiagnostic builder pattern in Biome?
diagnostics-development teaches the RuleDiagnostic builder pattern as the primary way to construct diagnostics for lint rules. This pattern lets you chain methods to set messages, advice, code frames, severity, and tags. The builder approach keeps diagnostic creation readable and maintainable, and the skill shows how to register diagnostic categories and configure severity levels to match your rule's intent.
How do I register diagnostic categories and set severity levels?
diagnostics-development covers registering diagnostic categories to organize your lint rules and configuring severity levels—error, warning, or hint—to control how Biome reports issues. Proper categorization and severity configuration ensure your diagnostics integrate smoothly with Biome's configuration system and user expectations, making linting output consistent and predictable.
What markup formatting and derive macros does Biome diagnostics support?
diagnostics-development teaches markup formatting options for emphasis, code highlighting, and clarity in diagnostic messages. The skill covers the Diagnostic derive macro, which streamlines trait implementation, and shows how to combine markup with code frames and advice for polished, professional diagnostic output that users can quickly parse and act upon.
SKILL.md
Rendered from the published skill. Quoted content, verbatim.
Purpose
Use this skill when creating diagnostics - the error messages, warnings, and hints shown to users. Covers the Diagnostic trait, advice types, and best practices for clear, actionable messages.
Prerequisites
- Read
crates/biome_diagnostics/CONTRIBUTING.mdfor concepts - Understand Biome's Technical Principles
- Follow the "show don't tell" philosophy
Diagnostic Principles
- Explain what - State what the error is (diagnostic message)
- Explain why - Explain why it's an error (advice notes)
- Tell how to fix - Provide actionable fixes (code actions, diff advice, command advice)
Follow Technical Principles: - Informative: Explain, don't just state - Concise: Short messages, rich context via advices - Actionable:
(truncated - see the full file via the links below)
File tree — 1 file
.claude/skills/diagnostics-development/SKILL.md
Let your AI agent find skills like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.
wish › “Create and implement diagnostic error messages for Biome lint rules”
Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →
Related skills
This skill guides you through building new lint rules and assist actions for Biome. It covers rule scaffolding across multiple languages, implementation patterns with semantic analysis, code action setup, and the three-pillar diagnostic framework required for all rules. Use it when adding custom rules like noVar or useConst to Biome's codebase.
This skill establishes documentation standards for Biome developers writing comments and rustdoc in the codebase. It distinguishes three comment types—module docs for explanation, item docs for reference, and inline comments for rationale—and teaches which patterns to avoid. The core principle: write for future contributors with no access to your current context, stating how code works rather than how it came to be.
Code Linting runs unified checks across Python and JavaScript/TypeScript projects using ruff and Biome. It detects violations, applies safe auto-fixes for formatting and imports, and guides manual resolution of remaining issues.
This skill teaches you how to work with Biome's type inference engine and module graph architecture for building type-aware lint rules. It covers the three-phase type resolution process—local inference, module-level resolution, and cross-module full inference—plus the TypeReference pattern that prevents stale data in an IDE environment. Use it when implementing new type-aware rules, understanding type resolution, or working on type inference features.
This skill teaches you how to add parsing support for new languages to Biome by authoring grammars in ungrammar format, implementing lexers and token sources, and writing parse rules with robust error recovery. It covers list parsing patterns, conditional syntax handling, and testing workflows for the Biome codebase.
This skill walks you through building changesets for Biome pull requests that introduce user-facing changes—bug fixes, new features, rule updates, or formatter tweaks. It covers selecting the right change type (patch, minor, or major), formatting rules, and writing clear descriptions with examples. Use it whenever your PR needs a CHANGELOG entry.
More skills testing-codegen (Apache-2.0) · design-patterns (Apache-2.0) · biome (MIT) · biome-developer (Apache-2.0) · ultracite (MIT) · pull-request (Apache-2.0)