Skip to content

Commit

Permalink
docs: improve
Browse files Browse the repository at this point in the history
  • Loading branch information
dtscalac committed Jun 5, 2024
1 parent 7f46b26 commit 3d8c0d0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions catalyst_voices/lib/configs/bootstrap.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ import 'package:go_router/go_router.dart';
import 'package:url_strategy/url_strategy.dart';

/// Initializes and runs the application provided by the [builder].
///
/// When updating see docs for [bootstrapForTests].
Future<void> bootstrap(FutureOr<Widget> Function() builder) async {
WidgetsFlutterBinding.ensureInitialized();

Expand All @@ -32,6 +34,8 @@ Future<void> bootstrap(FutureOr<Widget> Function() builder) async {
/// - Must not override [FlutterError.onError].
/// - Must be synced with [bootstrap], to run exactly the same
/// initialization logic except for the above exclusions.
///
/// Keep the function close to [bootstrap] so that they get updated together.
Future<void> bootstrapForTests() async {
GoRouter.optionURLReflectsImperativeAPIs = true;
setPathUrlStrategy();
Expand Down

0 comments on commit 3d8c0d0

Please sign in to comment.