diff --git a/CHANGELOG.md b/CHANGELOG.md index 0a13e8b..ec7b909 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed + +- update linting rules — + [162](https://github.com/dartoos-dev/json_cache/issues/154). + + ## [3.0.2] - 2024-08-19 ### Changed diff --git a/analysis_options.yaml b/analysis_options.yaml index c4a5c19..39a6f3b 100644 --- a/analysis_options.yaml +++ b/analysis_options.yaml @@ -1,17 +1,17 @@ include: package:lint/package.yaml analyzer: - strong-mode: - implicit-casts: false - + exclude: + - '**.freezed.dart' + - '**.g.dart' linter: rules: # Make constructors the first thing in every class + sort_unnamed_constructors_first: true sort_constructors_first: true + avoid_catches_without_on_clauses: true + avoid_equals_and_hash_code_on_mutable_classes: true + cancel_subscriptions: true # Good packages document everything public_member_api_docs: true - always_declare_return_types: true - cancel_subscriptions: true - close_sinks: true - only_throw_errors: true - package_api_docs: true \ No newline at end of file + package_api_docs: true diff --git a/pubspec.yaml b/pubspec.yaml index 86ac6cf..b6a8227 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -22,6 +22,6 @@ dev_dependencies: flutter_test: sdk: flutter hive_test: ^1.0.1 - lint: ^2.0.1 + lint: ^2.3.0 mocktail: ^1.0.0 test: ^1.24.9