linter
Discontinued. This package is not intended to be used directly.
1.30.1
21K downloads/mo
#2159 most downloaded on pub.dev
dart-lang/linter
What this package is like to depend on
Last release 2 years ago
no release in 18 months
Ships unpredictably
gaps range from 9 days to 1.6 years
Nearly every release is documented
notes for 166 of 173 stable releases
Nothing withdrawn
no release was ever pulled
11 years old
175 releases · first in 2015
0 releases in the last 12 months
see the full history below
Release timeline
175 releases · Mar 2015 to Jun 2024
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
Releases
latest 60 of 175-
1.30.125 Jun 2024 -
1.30.009 Nov 2022Release notes
Open source →1.30.0
- new lint:
enable_null_safety - new lint:
library_annotations - miscellaneous documentation improvements
Release notes
Open source →- new lint:
enable_null_safety - new lint:
library_annotations - miscellaneous documentation improvements
- new lint:
-
1.29.004 Nov 2022Release notes
Open source →1.29.0
- new lint:
dangling_library_doc_comments - fix
no_leading_underscores_for_local_identifiersto not report super formals as local variables - fix
unnecessary_overridesfalse negatives - fix
cancel_subscriptionsfor nullable fields - new lint:
collection_methods_unrelated_type - update
library_namesto support unnamed libraries - fix
unnecessary_parenthesissupport for as-expressions - fix
use_build_context_synchronouslyto check for context property accesses - fix false positive in
comment_references - improved unrelated type checks to handle enums and cascades
- fix
unnecessary_brace_in_string_interpsforthisexpressions - update
use_build_context_synchronouslyforBuildContext.mounted - improve
flutter_style_todosto handle more cases - fix
use_build_context_synchronouslyto check forBuildContexts in named expressions - fix
exhaustive_casesto check parenthesized expressions - performance improvements for:
avoid_null_checks_in_equality_operatorsjoin_return_with_statementrecursive_gettersunnecessary_lambdasdiagnostic_describe_all_propertiesprefer_foreachavoid_escaping_inner_quotescascade_invocationstighten_type_of_initializing_formalsprefer_interpolation_to_compose_stringsprefer_constructors_over_static_methodsavoid_returning_nullparameter_assignmentsprefer_constructors_over_static_methodsprefer_interpolation_to_compose_stringsavoid_returning_nullavoid_returning_thisflutter_style_todosavoid_positional_boolean_parametersprefer_const_constructors
- new lint:
implicit_call_tearoffs - new lint:
unnecessary_library_directive
Release notes
Open source →- new lint:
dangling_library_doc_comments - fix
no_leading_underscores_for_local_identifiersto not report super formals as local variables - fix
unnecessary_overridesfalse negatives - fix
cancel_subscriptionsfor nullable fields - new lint:
collection_methods_unrelated_type - update
library_namesto support unnamed libraries - fix
unnecessary_parenthesissupport for as-expressions - fix
use_build_context_synchronouslyto check for context property accesses - fix false positive in
comment_references - improved unrelated type checks to handle enums and cascades
- fix
unnecessary_brace_in_string_interpsforthisexpressions - update
use_build_context_synchronouslyforBuildContext.mounted - improve
flutter_style_todosto handle more cases - fix
use_build_context_synchronouslyto check forBuildContexts in named expressions - fix
exhaustive_casesto check parenthesized expressions - performance improvements for:
avoid_null_checks_in_equality_operatorsjoin_return_with_statementrecursive_gettersunnecessary_lambdasdiagnostic_describe_all_propertiesprefer_foreachavoid_escaping_inner_quotescascade_invocationstighten_type_of_initializing_formalsprefer_interpolation_to_compose_stringsprefer_constructors_over_static_methodsavoid_returning_nullparameter_assignmentsprefer_constructors_over_static_methodsprefer_interpolation_to_compose_stringsavoid_returning_nullavoid_returning_thisflutter_style_todosavoid_positional_boolean_parametersprefer_const_constructors
- new lint:
implicit_call_tearoffs - new lint:
unnecessary_library_directive
- new lint:
-
1.28.001 Sep 2022Release notes
Open source →1.28.0
- update
avoid_redundant_argument_valuesto work with enum declarations - performance improvements for
prefer_contains - new lint:
unreachable_from_main - (internal): analyzer API updates and
DartTypeUtilitiesrefactoring
Release notes
Open source →- update
avoid_redundant_argument_valuesto work with enum declarations - performance improvements for
prefer_contains - new lint:
unreachable_from_main - (internal): analyzer API updates and
DartTypeUtilitiesrefactoring
- update
-
1.27.008 Aug 2022Release notes
Open source →1.27.0
- fix
avoid_redundant_argument_valueswhen referencing required
parameters in legacy libraries - performance improvements for
use_late_for_private_fields_and_variables - new lint:
use_string_in_part_of_directives - fixed
use_super_parametersfalse positive with repeated super
parameter references - updated
use_late_for_private_fields_and_variablesto handle enums - fixed
prefer_containsfalse positive when start index is non-zero - improved
noop_primitive_operationsto catch.toString()
in string interpolations - updated
public_member_api_docsto report diagnostics on extension
names (instead of bodies) - miscellaneous documentation improvements
- (internal):
DartTypeUtilitiesrefactoring
Release notes
Open source →- fix
avoid_redundant_argument_valueswhen referencing required parameters in legacy libraries - performance improvements for
use_late_for_private_fields_and_variables - new lint:
use_string_in_part_of_directives - fixed
use_super_parametersfalse positive with repeated super parameter references - updated
use_late_for_private_fields_and_variablesto handle enums - fixed
prefer_containsfalse positive when start index is non-zero - improved
noop_primitive_operationsto catch.toString()in string interpolations - updated
public_member_api_docsto report diagnostics on extension names (instead of bodies) - miscellaneous documentation improvements
- (internal):
DartTypeUtilitiesrefactoring
- fix
-
1.26.011 Jul 2022Release notes
Open source →1.26.0
- new lint:
combinators_ordering - fixed
use_colored_boxanduse_decorated_boxto not over-report
on containers without a child - fixed false positive for
unnecessary_parenthesison a map-or-set
literal at the start of an expression statement - fixed false positive for
prefer_final_localsreporting on fields - fixed
unnecessary_overridesto allow overrides on@Protected
members - fixed
avoid_multiple_declarations_per_linefalse positive in
forstatements - fixed
prefer_final_localsfalse positive on declaration lists
with at least one non-final variable - fixed
use_build_context_synchronouslyto handleawaits in
ifconditions
Release notes
Open source →- new lint:
combinators_ordering - fixed
use_colored_boxanduse_decorated_boxto not over-report on containers without a child - fixed false positive for
unnecessary_parenthesison a map-or-set literal at the start of an expression statement - fixed false positive for
prefer_final_localsreporting on fields - fixed
unnecessary_overridesto allow overrides on@Protectedmembers - fixed
avoid_multiple_declarations_per_linefalse positive inforstatements - fixed
prefer_final_localsfalse positive on declaration lists with at least one non-final variable - fixed
use_build_context_synchronouslyto handleawaits inifconditions
- new lint:
-
1.25.007 Jun 2022Release notes
Open source →- new lint:
discarded_futures - improved message and highlight range for
no_duplicate_case_values - performance improvements for
lines_longer_than_80_chars,prefer_const_constructors_in_immutables, andprefer_initializing_formals
- new lint:
-
1.24.018 May 2022Release notes
Open source →- fix
prefer_final_parametersto support super parameters - new lint:
unnecessary_to_list_in_spreads - fix
unawaited_futuresto handle string interpolated futures - update
use_colored_boxto not flag nullable colors - new lint:
unnecessary_null_aware_operator_on_extension_on_nullable
- fix
-
1.23.005 May 2022Release notes
Open source →- fixed
no_leading_underscores_for_local_identifiersto lint local function declarations - fixed
avoid_init_to_nullto correctly handle super initializing defaults that are non-null - updated
no_leading_underscores_for_local_identifiersto allow identifiers with just underscores - fixed
flutter_style_todosto support usernames that start with a digit - updated
require_trailing_commasto handle functions in asserts and multi-line strings - updated
unsafe_htmlto allow assignments toimg.src - fixed
unnecessary_null_checksto properly handle map literal entries
- fixed
-
1.22.028 Mar 2022Release notes
Open source →- fixed false positives for
unnecessary_getters_settersandprefer_final_fieldswith enhanced enums - updated to analyzer 3.4.0 APIs
- fixed null-safe variance in
invariant_booleans
- fixed false positives for
-
1.21.221 Mar 2022Release notes
Open source →- several
use_super_parametersfalse positive fixes - updated
depend_on_referenced_packagesto treatflutter_genas a virtual package, not needing an explicit dependency
- several
-
1.21.118 Mar 2022 -
1.21.017 Mar 2022Release notes
Open source →- fixed
use_key_in_widget_constructorsfalse positive withkeysuper parameter initializers - fixed
use_super_parametersfalse positive with field formal params - updated
unnecessary_null_checksandnull_check_on_nullable_type_parameterto handle list/set/map literals, andyieldandawaitexpressions
- fixed
-
1.20.014 Mar 2022Release notes
Open source →- renamed
use_super_initializerstouse_super_parameters - fixed
unnecessary_null_aware_assignmentsproperty-access false positive
- renamed
-
1.19.208 Mar 2022Release notes
Open source →- new lint:
use_super_initializers - new lint:
use_enums - new lint:
use_colored_box - performance improvements for
sort_constructors - doc improvements for
always_use_package_imports,avoid_print, andavoid_relative_lib_imports - update
avoid_void_asyncto skipmainfunctions - update
prefer_final_parametersto not super on super params - lint updates for enhanced-enums and super-initializer language features
- updated
unnecessary_lateto report on the variable name - marked
null_check_on_nullable_type_parameterstable
- new lint:
-
1.19.108 Mar 2022Nothing published for this version
-
1.19.007 Mar 2022Nothing published for this version
-
1.18.010 Jan 2022Release notes
Open source →- extend
camel_case_typesto cover enums - fix
no_leading_underscores_for_local_identifiersto not mis-flag field formal parameters with default values - fix
prefer_function_declarations_over_variablesto not mis-flag non-final fields - performance improvements for
prefer_contains - update
exhaustive_casesto skip deprecated values that redirect to other values
- extend
-
1.17.116 Dec 2021 -
1.17.016 Dec 2021Release notes
Open source →- new lint:
unnecessary_late - fix to
no_leading_underscores_for_local_identifiersto allow underscores in catch clauses
- new lint:
-
1.16.008 Dec 2021Release notes
Open source →- doc improvements for
prefer_initializing_formals - updates to
secure_pubspec_urlsto checkissue_trackerandrepositoryentries - new lint:
conditional_uri_does_not_exist - performance improvements for
missing_whitespace_between_adjacent_strings
- doc improvements for
-
1.15.023 Nov 2021Release notes
Open source →- new lint:
use_decorated_box - new lint:
no_leading_underscores_for_library_prefixes - new lint:
no_leading_underscores_for_local_identifiers - new lint:
secure_pubspec_urls - new lint:
sized_box_shrink_expand - new lint:
avoid_final_parameters - improved docs for
omit_local_variable_types
- new lint:
-
1.13.012 Oct 2021Release notes
Open source →- allow
while (true) { ...}inliteral_only_boolean_expressions - fixed
file_namesto report at the start of the file (not the entire compilation unit) - fixed
prefer_collection_literalsnamed typed param false positive - control flow improvements for
use_build_context_synchronously
- allow
-
1.12.020 Sep 2021Release notes
Open source →- fixed
unnecessary_lambdasfalse positive for const constructor invocations - updated
avoid_printto allowkDebugMode-wrapped print calls - fixed handling of initializing formals in
prefer_final_parameters - fixed
unnecessary_parenthesisfalse positive with function expressions
- fixed
-
1.11.007 Sep 2021Release notes
Open source →- added support for constructor tear-offs to
avoid_redundant_argument_values,unnecessary_lambdas, andunnecessary_parenthesis - new lint:
unnecessary_constructor_nameto flag unnecessary uses of.new
- added support for constructor tear-offs to
-
1.10.025 Aug 2021Release notes
Open source →- improved regular expression parsing performance for common checks
(
camel_case_types,file_names, etc.) - (internal) migrated to analyzer 2.1.0 APIs
- fixed false positive in
use_build_context_synchronouslyin awaits inside anonymous functions - fixed
overridden_fieldsfalse positive w/ static fields - fixed false positive in
avoid_null_checks_in_equality_operatorsw/ non-nullable params - fixed false positive for deferred imports in
prefer_const_constructors
- improved regular expression parsing performance for common checks
(
-
1.9.011 Aug 2021Release notes
Open source →- marked
avoid_dynamic_callsstable - (internal) removed unused
MockPubVisitorandMockRuleclasses - fixed
prefer_void_to_nullfalse positive w/ overridden properties - (internal) removed references to
NodeLintRulein lint rule declarations - fixed
prefer_void_to_nullfalse positive on overriding returns - fixed
prefer_generic_function_type_aliasesfalse positive w/ incomplete statements - fixed false positive for
prefer_initializing_formalswith factory constructors - fixed
void_checksfalse positives with incomplete source - updated
unnecessary_getters_settersto only flag the getter - improved messages for
avoid_renaming_method_parameters - fixed false positive in
prefer_void_to_null - fixed false positive in
omit_local_variable_types - fixed false positive in
use_rethrow_when_possible - performance improvements for
annotate_overrides,prefer_contains, andprefer_void_to_null
- marked
-
1.8.026 Jul 2021Release notes
Open source →- performance improvements for
prefer_is_not_empty - fixed false positive in
no_logic_in_create_state - improve
package_namesto allow dart identifiers as package names - fixed false-positive in
package_names(causing keywords to wrongly get flagged) - fixed
avoid_classes_with_only_static_memberto check for inherited members and also flag classes with only methods - fixed
curly_braces_in_flow_control_structuresto properly flag terminatingelse-ifblocks - improved
always_specify_typesto support type aliases - fixed false positive in
unnecessary_string_interpolationsw/ nullable interpolated strings - fixed false positive in
avoid_function_literals_in_foreach_callsfor nullable iterables - fixed false positive in
avoid_returning_nullw/ NNBD - fixed false positive in
use_late_for_private_fields_and_variablesin the presence of const constructors - new lint:
eol_at_end_of_file - updated
analyzerconstraint to>=2.0.0 <3.0.0
- performance improvements for
-
1.7.105 Jul 2021Release notes
Open source →- Update
analyzerconstraint to>=1.7.0 <3.0.0. - Update
metaconstraint to>=1.3.0 <3.0.0.
- Update
-
1.7.030 Jun 2021Release notes
Open source →- fixed case-sensitive false positive in
use_full_hex_values_for_flutter_colors - improved try-block and switch statement flow analysis for
use_build_context_synchronously - updated
use_setters_to_change_propertiesto only highlight a method name, not the entire body and doc comment - updated
unnecessary_getters_settersto allow otherwise "unnecessary" getters and setters with annotations - updated
missing_whitespace_between_adjacent_stringsto allow String interpolations at the beginning and end of String literals - updated
unnecessary_getters_settersto allow for setters with non-basic assignments (for example,??=or+=)
- fixed case-sensitive false positive in
-
1.6.115 Jun 2021Release notes
Open source →- reverted relaxation of
sort_child_properties_lastto allow for a trailing Widget in instance creations
- reverted relaxation of
-
1.6.014 Jun 2021Release notes
Open source →- relaxed
non_constant_identifier_namesto allow for a trailing underscore - fixed false negative in
prefer_final_parameterswhere first parameter is final - improved
directives_orderingsorting of directives with dot paths and dot-separated package names - relaxed
sort_child_properties_lastto allow for a trailing Widget in instance creations
- relaxed
-
1.5.001 Jun 2021Release notes
Open source →- (internal) migrated to
SecurityLintCodeinstead of deprecatedSecurityLintCodeWithUniqueName - (internal) fixed
avoid_types_as_parameter_namesto skip field formal parameters - fixed false positives in
prefer_interpolation_to_compose_stringswhere the left operand is not a String - fixed false positives in
only_throw_errorsfor misidentified type variables - new lint:
depend_on_referenced_packages - update
avoid_returning_null_for_futureto skip checks for null-safe libraries - new lint:
use_test_throws_matchers - relax
sort_child_properties_lastto accept closures after child - performance improvements for
prefer_containsandprefer_is_empty - new lint:
noop_primitive_operations - mark
avoid_web_libraries_in_flutteras stable - new lint:
prefer_final_parameters - update
prefer_initializing_formalsto allow assignments where identifier names don't match
- (internal) migrated to
-
1.4.020 Apr 2021Release notes
Open source →directives_orderingnow checks ordering ofpackage:imports in code outside pub packages- simple reachability analysis added to
use_build_context_synchronouslyto short-circuit await-discovery in terminating blocks use_build_context_synchronouslyupdated to recognize nullable types when accessed from legacy libraries
-
1.3.013 Apr 2021Release notes
Open source →non_constant_identifier_namesupdated to check local variables, for-loop initializers and catch clauses- error range of
lines_longer_than_80_charsupdated to start at 80 to make splitting easier - new lint:
require_trailing_commas - new lint:
prefer_null_aware_method_calls
-
1.2.122 Mar 2021 -
1.2.022 Mar 2021Release notes
Open source →- improvements to
iterable_contains_unrelated_typeto better supportListcontent checks - fixes to
camel_case_typesandprefer_mixinto support non-function type aliases
- improvements to
-
1.1.017 Mar 2021Release notes
Open source →- fixed
prefer_mixinto properly make exceptions fordart.collectionlegacy mixins - improved formatting of source examples in docs
- new lint:
use_build_context_synchronously(experimental) - new lint:
avoid_multiple_declarations_per_line
- fixed
-
1.0.003 Mar 2021Release notes
Open source →- full library migration to null-safety
- new lint:
use_if_null_to_convert_nulls_to_bools - new lint:
deprecated_consistency - new lint:
use_named_constants - deprecation of
avoid_as
-
0.1.12921 Jan 2021Release notes
Open source →- fixed a bug where
avoid_dynamic_callsproduced false-positives for.call()
- fixed a bug where
-
0.1.12709 Dec 2020Release notes
Open source →- fixed crash in
prefer_collection_literalswhen there is no static parameter element
- fixed crash in
-
0.1.12630 Nov 2020Release notes
Open source →- fixed false negatives for
prefer_collection_literalswhen a LinkedHashSet or LinkedHashMap instantiation is passed as the argument to a function in any position other than the first - fixed false negatives for
prefer_collection_literalswhen a LinkedHashSet or LinkedHashMap instantiation is used in a place with a static type other than Set or Map
- fixed false negatives for
-
0.1.12511 Nov 2020 -
0.1.12406 Nov 2020Release notes
Open source →- fixed false positives in
prefer_constructors_over_static_methods - updated
package_namesto allow leading underscores
- fixed false positives in
-
0.1.12304 Nov 2020 -
0.1.12230 Oct 2020Release notes
Open source →- fixed NPE in
unnecessary_null_checks - fixed NPE in
missing_whitespace_between_adjacent_strings - updated
void_checksfor NNBD - fixed range error in
unnecessary_string_escapes - fixed false positives in
unnecessary_null_types - fixed
prefer_constructors_over_static_methodsto respect type parameters - updated
always_require_non_null_named_parametersto be NNBD-aware - updated
unnecessary_nullable_for_final_variable_declarationsto allow dynamic - update
overridden_fieldsto not report on abstract parent fields - fixes to
unrelated_type_equality_checksfor NNBD - improvement to
type_init_formalsto allow types not equal to the field type
- fixed NPE in
-
0.1.12108 Oct 2020Release notes
Open source →- performance improvements to
always_use_package_imports,avoid_renaming_method_parameters,prefer_relative_importsandpublic_member_api_docs - (internal): update to analyzer
0.40.4APIs
- performance improvements to
-
0.1.12001 Oct 2020Release notes
Open source →- new lint:
cast_nullable_to_non_nullable - new lint:
null_check_on_nullable_type_parameter - new lint:
tighten_type_of_initializing_formals - update
public_member_apisto check generic type aliases - (internal): update to new analyzer APIs
- new lint:
-
0.1.11902 Sep 2020Release notes
Open source →- fix
close_sinksto handlethis-prefixed property accesses - new lint:
unnecessary_null_checks - fix
unawaited_futuresto handleFuturesubtypes - new lint:
avoid_type_to_string
- fix
-
0.1.11806 Aug 2020Release notes
Open source →- new lint:
unnecessary_nullable_for_final_variable_declarations - fixed NPE in
prefer_asserts_in_initializer_lists - fixed range error in
unnecessary_string_escapes unsafe_htmlupdated to support unique error codes- updates to
diagnostic_describe_all_propertiesto check forDiagnosticables (notDiagnosticableMixins) - new lint:
use_late - fixed
unnecessary_lambdasto respect deferred imports - updated
public_member_api_docsto check mixins - updated
unnecessary_statementsto skipasexpressions - fixed
prefer_relative_importsto work with path dependencies
- new lint:
-
0.1.11709 Jun 2020Release notes
Open source →- fixed
directives_orderingto remove third party package special-casing - fixed
unnecessary_lambdasto check for tearoff assignability - fixed
exhaustive_casesto not flag missing cases that are defaulted - fixed
prefer_is_emptyto special-case assert initializers and const contexts - test utilities moved to:
lib/src/test_utilities - new lint:
do_not_use_environment
- fixed
-
0.1.11605 May 2020Release notes
Open source →- new lint:
no_default_cases(experimental) - new lint:
exhaustive_cases - updated
type_annotate_public_apisto allow inferred types in final field assignments - updated
prefer_mixinto allow "legacy" SDK abstract class mixins - new lint:
use_is_even_rather_than_modulo - update
unsafe_htmlto use aSecurityLintCode(making it un-ignorable) - improved
sized_box_for_whitespaceto address false-positives
- new lint:
-
0.1.11510 Apr 2020Release notes
Open source →- updated
avoid_types_as_parameter_namesto check catch-clauses - fixed
unsafe_htmlto check attributes and methods on extensions - extended
unsafe_htmlto includeWindow.open,Element.htmlandDocumentFragment.htmlin unsafe API checks - improved docs for
sort_child_properties_last - (internal)
package:analyzerAPI updates - new lint:
sized_box_for_whitespace
- updated
-
0.1.11425 Mar 2020Release notes
Open source →- fixed
avoid_shadowing_type_parametersto support extensions and mixins - updated
non_constant_identifier_namesto allow named constructors made up of only underscores (_) - updated
avoid_unused_constructor_parametersto ignore unused params named in all underscores (_)
- fixed
-
0.1.11317 Mar 2020Release notes
Open source →- updated documentation links
one_member_abstractsupdated to not lint classes with mixins or implementing interfacesunnecessary_getters_settersfixed to ignore cases where a getter/setter is deprecated- new lint:
leading_newlines_in_multiline_strings - improved highlight ranges for
avoid_private_typedef_functionsandavoid_returning_null_for_future
-
0.1.11228 Feb 2020Release notes
Open source →- marked
prefer_typing_uninitialized_variablesandomit_local_variable_typesas compatible
- marked
-
0.1.11125 Feb 2020Nothing published for this version
-
0.1.111+125 Feb 2020Release notes
Open source →- new lint:
use_raw_strings - new lint:
unnecessary_raw_strings - new lint:
avoid_escaping_inner_quotes - new lint:
unnecessary_string_escapes - incompatible rule documentation improvements
- new lint:
-
0.1.11027 Jan 2020Release notes
Open source →- fixed flutter web plugin detection in
avoid_web_libraries_in_flutter - new lint:
unnecessary_string_interpolations - new lint:
missing_whitespace_between_adjacent_strings avoid_unused_constructor_parametersupdated to ignore deprecated parameters- new lint:
no_runtimeType_toString - miscellaneous doc fixes
- fixed flutter web plugin detection in
-
0.1.10915 Jan 2020Release notes
Open source →- improved
prefer_single_quoteslint message unnecessary_finalsfixed to not flag fieldsunnecessary_lambdasfixed to work with type arguments- (internal) migrated to use analyzer
LinterContext.resolveNameInScope()API
- improved