-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathanalysis_options.yaml
More file actions
98 lines (90 loc) · 2.92 KB
/
analysis_options.yaml
File metadata and controls
98 lines (90 loc) · 2.92 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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# This file configures the analyzer, which statically analyzes Dart code to
# check for errors, warnings, and lints.
#
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
# invoked from the command line by running `flutter analyze`.
# The following line activates a set of recommended lints for Flutter apps,
# packages, and plugins designed to encourage good coding practices.
include: package:very_good_analysis/analysis_options.yaml
analyzer:
exclude:
- build/**
- "**/*.g.dart"
- "**/*.freezed.dart"
- "**/*.graphql.dart"
- test/.test_coverage.dart
- lib/generated_plugin_registrant.dart
- lib/firebase_options.dart
language:
strict-casts: true
strict-inference: true
strict-raw-types: true
errors:
#recommend to ignore by freezed package author:
#https://github.com/rrousselGit/freezed/issues/488#issuecomment-894358980
invalid_annotation_target: ignore
missing_required_param: error
missing_return: error
plugins:
linter:
rules:
public_member_api_docs: false
sort_pub_dependencies: false
avoid_positional_boolean_parameters: false
flutter_style_todos: false
always_put_required_named_parameters_first: false
# Learn more: https://dcm.dev/docs/individuals/configuration
dart_code_metrics:
extends:
- recommended
metrics:
cyclomatic-complexity: 20
number-of-parameters: 4
maximum-nesting-level: 5
metrics-exclude:
- test/**
- build/**
- "**/*.g.dart"
- "**/*.freezed.dart"
- "**/*.graphql.dart"
- lib/generated_plugin_registrant.dart
- lib/firebase/firebase_options.dart
rules:
prefer-match-file-name: true
# prefer-single-widget-per-file: false
# avoid-nullable-interpolation: false
# avoid-unsafe-collection-methods: false
# rules:
# - avoid-dynamic
# - avoid-passing-async-when-sync-expected
# - avoid-redundant-async
# - avoid-unnecessary-type-assertions
# - avoid-unnecessary-type-casts
# - avoid-unrelated-type-assertions
# - avoid-unused-parameters
# - newline-before-return
# - no-boolean-literal-compare
# - no-empty-block
# - prefer-trailing-comma
# - prefer-conditional-expressions
# - no-equal-then-else
# - dispose-fields
# - avoid-unnecessary-overrides-in-state
# - avoid-unnecessary-setstate
# - avoid-shadowing
# - avoid-unnecessary-nullable-return-type
# - prefer-declaring-const-constructor
# - prefer-return-await
# - always-remove-listener
# - use-setstate-synchronously
# - avoid-incomplete-copy-with
# - proper-super-calls
# - avoid-border-all
# - avoid-inherited-widget-in-initstate
# - avoid-late-context
# - avoid-missing-controller
# - avoid-missing-image-alt
# - avoid-recursive-widget-calls
# - avoid-returning-widgets
# - avoid-unassigned-stream-subscriptions