linter_rules

Last updated:

0 purchases

linter_rules Image
linter_rules Images
Add to Cart

Description:

linter rules

Create your own linter by process of elimination from all rules except experimental and deprecated.
Usage #
1.Add linter_rules to dev_dependencies.
dev_dependencies:
linter_rules: ^0.0.5
copied to clipboard
2.Include linter_rules in analysis_options.yaml.
include: package:linter_rules/analysis_options.yaml
copied to clipboard
Incompatible rules #
# default
#
# DO avoid relative imports for files in lib/.
#
# https://dart.dev/tools/linter-rules#always_use_package_imports
- always_use_package_imports


# or


# PREFER relative imports for files in lib/.
#
# https://dart.dev/tools/linter-rules#prefer_relative_imports
- prefer_relative_imports
copied to clipboard
# DO specify type annotations.
#
# https://dart.dev/tools/linter-rules#always_specify_types
- always_specify_types


# or


# default
#
# AVOID annotating types for function expression parameters.
#
# https://dart.dev/tools/linter-rules#avoid_types_on_closure_parameters
- avoid_types_on_closure_parameters

# and

# DON’T redundantly type annotate initialized local variables.
#
# https://dart.dev/tools/linter-rules#omit_local_variable_types
- omit_local_variable_types
copied to clipboard
# AVOID declaring parameters as final.
#
# https://dart.dev/tools/linter-rules#avoid_final_parameters
- avoid_final_parameters

# and

# Use var, not final, when declaring local variables.
#
# https://dart.dev/tools/linter-rules#unnecessary_final
- unnecessary_final


# or


# default
#
# DO prefer declaring variables as final if they are not reassigned later in the code.
#
# https://dart.dev/tools/linter-rules#prefer_final_locals
- prefer_final_locals

# and

# DO prefer declaring parameters as final if they are not reassigned in the function body.
#
# https://dart.dev/tools/linter-rules#prefer_final_parameters
- prefer_final_parameters
copied to clipboard
# DO use double quotes where they wouldn’t require additional escapes.
#
# https://dart.dev/tools/linter-rules#prefer_double_quotes
- prefer_double_quotes


# or


# default
#
# DO use single quotes where they wouldn’t require additional escapes.
#
# https://dart.dev/tools/linter-rules#prefer_single_quotes
- prefer_single_quotes
copied to clipboard

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.