SShortSingh.
Back to feed

house_rules: Writing Flutter project lint rules in YAML instead of custom analyzer plugins

0
·1 views

The author argues that project conventions, such as using design tokens rather than raw colors or preventing cross-layer imports, are usually documented in wikis and go unenforced. Dart's analyzer cannot easily express such rules, and custom analyzer plugins require a separate package and ongoing maintenance. To address this, they created house_rules, a tool where each rule is defined in a few lines of YAML and ships with ten built-in rules. It includes a baseline feature so existing violations do not fail CI while only new problems do. On a 2,937-file Flutter app, the tool reportedly checks the whole project in about 0.285 seconds, and it requires Dart 3.11 or newer.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingHacker News ·

Jev 1.14 Released With Features Aimed at Builders and Dreamers

Jev version 1.14 has been announced on the typesafe.ai blog, according to a Hacker News post. The source material provided is limited to the headline, the link to the release post, and basic Hacker News metadata showing 7 points and no comments. The announcement is framed as being for builders and dreamers, but the specific features and changes in this release are not described in the available text. Further details would need to be confirmed by reading the original blog post directly.

0
ProgrammingDEV Community ·

Resume Tip: Use Problem-Action-Result Bullets with Numbers to Stand Out to Recruiters

A software engineer describes months of unanswered job applications and concluded that resumes were not conveying their impact clearly enough. Analyzing successful engineering resumes, the author found a recurring pattern: bullet points structured as Problem, Action, and Result, with a quantifiable outcome. The article contrasts vague task-list bullets with rewritten examples that cite specific latency reductions, recovered revenue, and test coverage gains. It also lists common pitfalls such as weak verbs, missing metrics, omitted tech stacks, and overly long bullets. The author recommends keeping each bullet to two lines and naming the tools used so both recruiters and applicant tracking systems can parse it easily.

0
ProgrammingDEV Community ·

New l10n_health tool audits Flutter translation files for unused and missing keys

A developer built l10n_health, a tool that checks Flutter translation files alongside Dart code for problems the analyzer misses. It reports unused keys, missing or untranslated entries across languages, mismatched placeholders, hardcoded text that bypasses localization, and hidden invisible Unicode characters. The tool works with gen_l10n and flutter_intl and can be installed globally or as a dev dependency. It also includes a careful prune command that removes unused keys as a text edit after validating the JSON, and can produce HTML, GitLab, and GitHub reports for CI.

0
ProgrammingDEV Community ·

Retry With Backoff and Jitter: A Reusable Pattern for Failed API Calls

A developer shares a retry function they reuse across projects, built to keep a single failed API call from overwhelming a backend. The article argues that naive retry loops, especially those with fixed delays, cause synchronized retry storms that prolong outages. The approach combines exponential backoff with full jitter so clients spread their retries out instead of firing together. It retries only on specific statuses like 429 and 503, respects Retry-After headers, and warns against retrying non-idempotent writes without idempotency keys. The author suggests starting with a 200ms base delay, a 30-second cap, and five attempts, then tuning based on observed failures.