refactor: Add Flutter lints
This commit is contained in:
parent
7a1eded1bb
commit
2b2b96872d
6 changed files with 16 additions and 12 deletions
|
|
@ -22,6 +22,7 @@ analyzer:
|
|||
|
||||
dart_code_linter:
|
||||
rules:
|
||||
# Dart specific:
|
||||
- avoid-dynamic
|
||||
- avoid-redundant-async
|
||||
- avoid-unnecessary-type-assertions
|
||||
|
|
@ -47,4 +48,13 @@ dart_code_linter:
|
|||
# message: 'Do not import Flutter Material Design library, we should not depend on it!'
|
||||
# - no-magic-number:
|
||||
# allowed: [-1, 0, 1,2,4,6,8,12,16,32,40,56,64]
|
||||
# allow-only-once: true
|
||||
# allow-only-once: true
|
||||
# Flutter specific:
|
||||
- prefer-media-query-direct-access
|
||||
- avoid-wrapping-in-padding
|
||||
- prefer-correct-edge-insets-constructor
|
||||
# TODO:
|
||||
# - avoid-returning-widgets
|
||||
# - prefer-single-widget-per-file:
|
||||
# ignore-private-widgets: true
|
||||
# - prefer-extracting-callbacks
|
||||
Loading…
Add table
Add a link
Reference in a new issue