-
Notifications
You must be signed in to change notification settings - Fork 4
/
analysis_options.yaml
53 lines (50 loc) · 1.68 KB
/
analysis_options.yaml
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
# 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:flutter_lints/flutter.yaml
linter:
rules:
- always_use_package_imports
- avoid_dynamic_calls
- avoid_relative_lib_imports
# - always_declare_return_types
# - avoid_types_on_closure_parameters
- cascade_invocations
- combinators_ordering
- constant_identifier_names
- directives_ordering
- discarded_futures
- empty_statements
# - omit_local_variable_types
- no_wildcard_variable_uses
- prefer_adjacent_string_concatenation
- prefer_conditional_assignment
- prefer_contains
- prefer_expression_function_bodies
- avoid_final_parameters # prefer_final_parameters
- prefer_final_in_for_each
- prefer_final_locals
- prefer_if_elements_to_conditional_expressions
- prefer_single_quotes
- require_trailing_commas
- sort_constructors_first
- sort_unnamed_constructors_first
- unawaited_futures
- unnecessary_breaks
# - unnecessary_lambdas
# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
analyzer:
# enable-experiment:
# - records
# - patterns
exclude:
- "**/*.freezed.dart"
- "**/*.g.dart"
errors:
invalid_annotation_target: ignore