Metrics
Metrics are grouped by category to help you understand their purpose.
- ✅ - this metric is included into the
metrics-recommendedpreset - ⚙️ - this metric has additional configuration options
Function / Method Metrics 9 metrics
Measures how much information does the reader of the code have to absorb to understand its meaning
Measures the total number of lines a function/method/constructor has (including its signature, parameters, all blank lines and comments)
Measures the maximum number of nested blocks that are present in a function/method
Measures the total number of used widgets in every method that returns a widget (e.g. build)
Measures the number of lines in the body of a function/method/constructor, excluding blank lines and comments
Measures the maximum number of nested widgets in every method that returns a widget (e.g. build)
Class Metrics 10 metrics
Measures the number of distinct classes to which a given class/mixin/enum/extension type is coupled
Measures the maximum inheritance path, referring to the number of levels a class is from the root class in an inheritance hierarchy
Measures the total number of methods that a class defines on its own, separate from those it inherits from parent classes
Measures the number of interfaces a class/enum/mixin implements (including direct and indirect interfaces)
Measures the total number of declared methods in a class/extension/mixin/enum/extension type
Measures the number of methods a class/mixin/enum overrides from its superclass or interface
Measures the number of uniquely invoked methods plus the number of methods in the class/mixin/enum/extension/extension type
Measures how well the methods of a class are related to each other by sharing access to at least one common instance field declared in that class
Measures the sum of the cyclomatic complexity of all methods in a class/extension/mixin/enum/extension type
File Metrics 3 metrics
Measures the number of dart: and all package: imports coming from pub dependencies
The cost of additional rework caused by choosing an easy (limited) solution now instead of using a better approach that would take longer