voyager 0.6.1 voyager: ^0.6.1 copied to clipboard
Router and basic dependency injection library for Flutter. Define navigation paths in YAML and power them up with custom plugins.
0.6.1 #
- display information in case
dartfmt
is missing from your path and you're using code generation tool.
0.6.0 #
SOME BREAKING CHANGES #
VoyagerWidget
becomes stateless by default. If you want to have stateful behavior, please useVoyagerStatefulWidget
- Dropped
Voyager.fromPath
method, it was redundant and confusing. Use constructor directly instead. - It is now recommended to wrap your app with
Provider<RouterNG>
. By doing this you can ommit passing the router parameter to everyVoyagerWidget
and thus making widget tree more compact sinceVoyagerWidget
don't have to provide router instance themselves.
Provider<RouterNG>.value(
value: router,
child: MaterialApp(
home: VoyagerWidget(path: initalPath),
onGenerateRoute: router.generator()
)
)
VoyagerWidget
has now extra cache parameter, meaning it will use RouterNG's caching internally to resolveVoyager
instance faster. Depending on your use case you might want to use this or not. SuchVoyager
instance has no parent.
The decision to change VoyagerWidget
to stateless widget and removal of fromPath
method was an inspiration after reading the following articles:
- Splitting Widgets To Methods is A Performance Antipattern - Iiro Krankka
- Flutter: Reducing widgets boilerplate - Remi Rousselet
It's a MUST READ for any Flutter developer.
0.5.2 #
- update to patched code generator version
0.5.1 #
- decrease occurences of voyager instance creation
0.5.0 #
You will be automated, resistance is futile.
BREAKING CHANGES #
- automated widget tests (EXPERIMENTAL)
- removal of deprecated
VoyagerProvider
, see version0.2.0
for migration steps (VoyagerProvider will return in a changed form...) - removal of
TypePlugin
- it's redundant, omit it in plugins list but still usetype
in your specs for code generation goodness RedirectPlugin
, allows mapping virtual paths to existing onesScreenPlugin
is now calledWidgetPlugin
, you also need to changescreen
towidget
in your yaml/json specs
0.4.2 #
- use
dartfmt
to make sure generated code is formatted corectly
0.4.1 #
- package health
0.4.0 #
- code generation for paths, simply run
flutter packages pub run voyager:codegen
at the top of your flutter project and behold!
0.3.0 #
- drop angel_route dependency in favor of abstract_router.dart
0.2.3 #
- json support
0.2.2 #
- formatting
0.2.1 #
- fixes around how VoyagerWidget reacts to hot reload
- improve sample app
- add a sample app gif to README
0.2.0 #
API DEPRECATION
VoyagerProvider
is being phased out. Internally Voyager will depend on provider more popular within the community.
Migration:
- change
VoyagerProvider.of(context)
toProvider.of<Voyager>(context)
- change
VoyagerProvider.routerOf(context)
toProvider.of<RouterNG>(context)
0.1.1 #
- Package health fixes
0.1.0 #
- Initial release