router function
Builder
router(
- BuilderOptions options
Main entrance of the builder, it will be used in build.yaml
Implementation
Builder router(BuilderOptions options) {
return PartBuilder(
[GoRouterGenerator()],
'.router.dart',
header: '''
// coverage:ignore-file
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
''',
options: options,
allowSyntaxErrors: true,
);
}