kevmoo avatar

Dart Best Practices

Concise guidance for idiomatic Dart covering multi-line strings and line length, with explicit abstention rules.

CCM score
57 of 100
skills.sh installs
852
GitHub stars
149
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers code style for Dart, focusing on multi-line string literals and an 80-character line length limit
  • Includes a "when NOT to use" list: public API breaking changes, micro-optimizations, generated files, and explicit public type annotations
  • Enforces readable wrapping via the lines_longer_than_80_chars analyzer lint and regex searches for +-based string concatenation
  • Designed for Dart developers writing or reviewing code, with a pointer to dart-modern-features for newer language features

Install

$ npx -y skills add kevmoo/dash_skills --skill dart-best-practices -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Dart Best Practices

1. When to use this skill

Use this skill when:

  • Writing or reviewing Dart code.
  • Looking for guidance on idiomatic Dart usage.

When NOT to use (Abstention Guardrails)

Do NOT apply this skill or refactor code when:

  • Public API Breaking Changes: Refactoring would alter public API contracts, return types, or parameter signatures in published packages without a coordinated major SemVer bump.
  • Dogmatic Micro-Optimizations: Rewriting clear, readable code for negligible theoretical gains (e.g. replacing clear string concatenation in a simple one-line log message with multiline quotes).
  • Domain-Specific or Code-Generated Files: Generated files (*.g.dart, *.freezed.dart, protobufs) or files where line lengths and string layouts are managed by code generators.
  • Explicit Type Annotations in Public Interfaces: Replacing explicit type annotations with var or final where explicit types document the public API surface or disambiguate complex generics.

2. Best Practices

Multi-line Strings

Details

Repository
github.com/kevmoo/dash_skills
Category
Code Review & Quality
First seen
May 16, 2026

More from kevmoo/dash_skills

All 6

Similar to Dart Best Practices

More Code Review & Quality