-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathanalysis_options.yaml
More file actions
79 lines (77 loc) · 2.08 KB
/
Copy pathanalysis_options.yaml
File metadata and controls
79 lines (77 loc) · 2.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
include: package:flutter_lints/flutter.yaml
analyzer:
plugins:
- dart_code_metrics
dart_code_metrics:
anti-patterns:
- long-method
- long-parameter-list
metrics:
cyclomatic-complexity: 20
maximum-nesting-level: 5
number-of-parameters: 4
source-lines-of-code: 50
metrics-exclude:
- test/**
- '**/*.g.dart'
- 'build/**'
rules:
# Common
- avoid-collection-methods-with-unrelated-types
- avoid-duplicate-exports
- avoid-dynamic
- avoid-global-state
- avoid-late-keyword
- avoid-missing-enum-constant-in-map
- avoid-nested-conditional-expressions
- avoid-non-ascii-symbols
- avoid-throw-in-catch-block
- avoid-unnecessary-type-assertions
- avoid-unnecessary-type-casts
- avoid-unrelated-type-assertions
- avoid-unused-parameters
- binary-expression-operand-order
- double-literal-format
- member-ordering-extended:
order:
- build-method
- init-state-method
- did-change-dependencies-method
- did-update-widget-method
- dispose-method
- no-boolean-literal-compare
- no-empty-block
- no-equal-then-else
- no-magic-number:
allowed: [-1, 0, 1, 2]
- no-object-declaration
- prefer-commenting-analyzer-ignores
- prefer-conditional-expressions
- prefer-correct-identifier-length:
min-identifier-length: 2
- prefer-correct-type-name
- prefer-enums-by-name
- prefer-first
- prefer-immediate-return
- prefer-last
- prefer-moving-to-variable
- prefer-trailing-comma
- tag-name
# Flutter
- always-remove-listener
- avoid-border-all
- avoid-returning-widgets
- avoid-shrink-wrap-in-lists
- avoid-unnecessary-setstate
- avoid-use-expanded-as-spacer
- avoid-wrapping-in-padding
- prefer-const-border-radius
- prefer-correct-edge-insets-constructor
- prefer-extracting-callbacks
- always-use-package-imports
- prefer-single-widget-per-file:
ignore-private-widgets: true
rules-exclude:
- test/**
- '**/*.g.dart'
- 'build/**'