Skip to content

Commit 4c1e780

Browse files
committed
refactor: update lint rules (#121)
1 parent 7b83894 commit 4c1e780

File tree

10 files changed

+13
-11
lines changed

10 files changed

+13
-11
lines changed

analysis_options.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
include: package:very_good_analysis/analysis_options.3.0.1.yaml
1+
include: package:very_good_analysis/analysis_options.5.1.0.yaml

example/analysis_options.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
include: package:very_good_analysis/analysis_options.3.0.1.yaml
1+
include: package:very_good_analysis/analysis_options.5.1.0.yaml
22
linter:
33
rules:
44
public_member_api_docs: false

example/lib/authentication_flow/authentication_flow.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ class _OnboardingPageState extends State<OnboardingPage> {
129129
}
130130

131131
class OnboardingStep extends StatelessWidget {
132-
const OnboardingStep({super.key, required this.step});
132+
const OnboardingStep({required this.step, super.key});
133133

134134
static Page<void> page(int step) {
135135
return MaterialPage<void>(child: OnboardingStep(step: step));

example/lib/location_flow/pages/city_selection/city_selection.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import 'package:flutter/material.dart';
55
import 'package:flutter_bloc/flutter_bloc.dart';
66

77
class CitySelection extends StatelessWidget {
8-
const CitySelection({super.key, required this.state});
8+
const CitySelection({required this.state, super.key});
99

1010
static MaterialPage<void> page({required String state}) {
1111
return MaterialPage<void>(child: CitySelection(state: state));

example/lib/location_flow/pages/state_selection/state_selection.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import 'package:flutter/material.dart';
55
import 'package:flutter_bloc/flutter_bloc.dart';
66

77
class StateSelection extends StatelessWidget {
8-
const StateSelection({super.key, required this.country});
8+
const StateSelection({required this.country, super.key});
99

1010
static MaterialPage<void> page({required String country}) {
1111
return MaterialPage<void>(child: StateSelection(country: country));

example/lib/location_flow/widgets/drop_down.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ import 'package:flutter/material.dart';
22

33
class Dropdown extends StatelessWidget {
44
const Dropdown({
5-
super.key,
65
required this.items,
76
required this.onChanged,
87
this.value,
98
this.hint,
9+
super.key,
1010
});
1111

1212
final Widget? hint;

example/lib/main.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import 'package:flutter_bloc/flutter_bloc.dart';
88
void main() => runApp(MyApp(locationRepository: LocationRepository()));
99

1010
class MyApp extends StatelessWidget {
11-
const MyApp({super.key, required LocationRepository locationRepository})
11+
const MyApp({required LocationRepository locationRepository, super.key})
1212
: _locationRepository = locationRepository;
1313

1414
final LocationRepository _locationRepository;

example/pubspec.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ environment:
88
flutter: ">=3.16.0 <4.0.0"
99

1010
dependencies:
11+
bloc: ^8.0.0
1112
equatable: ^2.0.0
1213
flow_builder:
1314
path: ../
@@ -16,7 +17,7 @@ dependencies:
1617
flutter_bloc: ^8.0.0
1718

1819
dev_dependencies:
19-
very_good_analysis: ^3.0.1
20+
very_good_analysis: ^5.1.0
2021

2122
flutter:
2223
uses-material-design: true

lib/flow_builder.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/// A Flutter package which simplifies flows with a flexible, declarative API.
12
library flow_builder;
23

34
import 'dart:collection';
@@ -42,13 +43,13 @@ typedef FlowCallback<T> = T Function(T state);
4243
class FlowBuilder<T> extends StatefulWidget {
4344
/// {@macro flow_builder}
4445
const FlowBuilder({
45-
super.key,
4646
required this.onGeneratePages,
4747
this.state,
4848
this.onComplete,
4949
this.controller,
5050
this.observers = const <NavigatorObserver>[],
5151
this.clipBehavior = Clip.hardEdge,
52+
super.key,
5253
}) : assert(
5354
state != null || controller != null,
5455
'requires either state or controller',
@@ -204,9 +205,9 @@ class _FlowBuilderState<T> extends State<FlowBuilder<T>> {
204205

205206
class _InheritedFlowController<T> extends InheritedWidget {
206207
const _InheritedFlowController({
207-
super.key,
208208
required this.controller,
209209
required super.child,
210+
super.key,
210211
});
211212

212213
final FlowController<T> controller;

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ dependencies:
1717
dev_dependencies:
1818
flutter_test:
1919
sdk: flutter
20-
very_good_analysis: ^3.0.1
20+
very_good_analysis: ^5.1.0

0 commit comments

Comments
 (0)