refactor: Add more linter rules
This commit is contained in:
parent
1cd3a91037
commit
7a1eded1bb
5 changed files with 28 additions and 11 deletions
|
|
@ -27,4 +27,24 @@ dart_code_linter:
|
|||
- avoid-unnecessary-type-assertions
|
||||
- avoid-unnecessary-type-casts
|
||||
- avoid-unrelated-type-assertions
|
||||
- no-boolean-literal-compare
|
||||
- no-boolean-literal-compare
|
||||
- no-equal-then-else
|
||||
- prefer-first
|
||||
- prefer-last
|
||||
- prefer-immediate-return
|
||||
- prefer-enums-by-name
|
||||
- avoid-unnecessary-conditionals
|
||||
# TODO:
|
||||
# - member-ordering
|
||||
# - avoid-late-keyword
|
||||
# - avoid-non-null-assertion
|
||||
# - avoid-global-state
|
||||
# - prefer-match-file-name
|
||||
# - avoid-banned-imports:
|
||||
# entries:
|
||||
# - paths: ['some/folder/.*\.dart', 'another/folder/.*\.dart']
|
||||
# deny: ['package:flutter/material.dart']
|
||||
# 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
|
||||
Loading…
Add table
Add a link
Reference in a new issue