Skip to content

Highly opinionated set of Dart and Flutter linter rules and analyzer setup

License

Notifications You must be signed in to change notification settings

notDmDrl/yet_another_lint

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Yet Another Lint

Common Changelog

Yet another lint rules package with a set of Dart and Flutter linter rules and analyzer setup. It's incredibly strict, with only around 10 to 15 rules disabled out of +-230, depending on the chosen set.

yet_another_lint provides 2 different sets of rules:

  • defaults - strict production-ready rule set. Uses 120 chars page width.
  • package - based on the defaults rule set with 4 additional rules, that make sense for package development, enabled. Uses 80 chars page width.

Important

The package's minimum Dart version is set to the version used by the latest Flutter Beta version.

For version 1.0.0 minimum Dart version is 3.7.0-209.1.beta

Enabling the lints

Add yet_another_lint as a dev dependency to your pubspec.yaml

dev_dependencies:
  yet_another_lint:
    git: https://github.com/notDmDrl/yet_another_lint.git

Create an analysis_options.yaml file in the root of your project with the following content:

# For production apps
include: package:yet_another_lint/defaults.yaml

or

# For packages with public API
include: package:yet_another_lint/package.yaml

depending on your chosen rule set.

Customizing the selected lint rule set.

For details on customizing static analysis beyond the predefined lint sets, see Customizing static analysis.


Note

This is a highly opinionated package created for the author's specific needs with no current intention for a public release via pub.dev. The only reason for the public repo is to be able to use the package outside my PC (ex. for work purposes).

About

Highly opinionated set of Dart and Flutter linter rules and analyzer setup

Topics

Resources

License

Stars

Watchers

Forks