unrouter 0.14.0
unrouter: ^0.14.0 copied to clipboard
Primary Unrouter package with Flutter, Nocterm, and shared core entrypoints.
Changelog #
0.14.0 #
Highlights #
Picks up breaking changes from unrouter_core 0.2.0, the new useRouter
helper in nocterm_unrouter 0.3.0, and the internal flutter_unrouter 0.2.1
refactor.
Breaking Changes #
RouteNode.metaandRouteRecord.metaare now non-nullable (Map<String, Object?>defaulting toconst {}). Seeunrouter_core0.2.0 migration notes.Unrouter.matcherandUnrouter.aliasesexposeroux.Router<T>which no longer has.match(). Use.find()instead.
What's New #
useRouter(context)is now available in thenocterm.dartentrypoint.
Migration Notes #
- Replace direct calls to
router.matcher.match(path)with.find(path). - Remove
?? const {}guards onmetafields — the value is always non-null.
0.13.0 #
Migration guide: See Migration note below.
Highlights #
Unrouter 0.13.0 turns the main package into the primary brand-level entrypoint
for the whole project. The package root now exposes shared core and history
APIs, while package:unrouter/flutter.dart and package:unrouter/nocterm.dart
provide the framework-specific adapters. This release also moves runnable demos
into workspace examples and aligns the published package with the new
multi-package layout.
Breaking Changes #
package:unrouter/unrouter.dartnow exports sharedunrouter_coreand history APIs instead of the old Flutter-specific router surface.- Flutter apps must import
package:unrouter/flutter.dartforInlet,Outlet,Link,createRouter, andcreateRouterConfig. - Nocterm apps must import
package:unrouter/nocterm.dartfor terminal router APIs such asRouterView,Inlet, andOutlet. - The package no longer ships the old single-package implementation from
0.12.x; framework APIs now come from the published adapter packages.
What's New #
Main-package entrypoints
- Added
package:unrouter/flutter.dartfor Flutter adapter exports. - Added
package:unrouter/nocterm.dartfor Nocterm adapter exports. - Kept
package:unrouter/unrouter.dartas the shared core and history entrypoint.
Workspace examples and package layout
- Moved runnable Flutter and Nocterm demos into top-level workspace examples.
- Split the codebase into publishable packages for
unrouter_core,flutter_unrouter, andnocterm_unrouterwhile keepingunrouteras the main package users install first.
Adapter alignment
- Updated the main package to depend on
flutter_unrouter ^0.2.0,nocterm_unrouter ^0.2.0, andunrouter_core ^0.1.0.
Migration note #
-
Flutter apps upgrading from
0.12.xshould replace:import 'package:unrouter/unrouter.dart';with:
import 'package:unrouter/flutter.dart'; -
Nocterm apps should import:
import 'package:unrouter/nocterm.dart'; -
Use
package:unrouter/unrouter.dartonly when you want shared routing and history APIs without a renderer-specific adapter. -
If you import multiple entrypoints in one file, use prefixes to avoid symbol collisions for
Inlet,Outlet,Unrouter, andcreateRouter.
Full Changelog #
0.12.0 #
Migration guide: Not required.
Highlights #
Unrouter 0.12.0 refined wildcard routing semantics to match upstream matching behavior and added support for named remainder wildcards in reverse routing.
Breaking Changes #
- None.
What's New #
Wildcard routing
- Upgraded route matching to
roux ^0.5.0and query parameter utilities toht ^0.3.0. - Added support for named remainder wildcards such as
**:wildcardin reverse routing.
Fixes and tests
- Aligned reverse-routing wildcard generation with upstream
rouxsemantics so*remains single-segment while**and**:namesupport remainder paths. - Added validation for empty wildcard parameter names in reverse routing patterns.
- Added coverage for single-segment wildcard validation, remainder wildcard expansion, and index child routes that share the parent path.
Migration note #
- No migration is required for this release.
0.11.0 #
Migration guide: Not required.
Highlights #
Unrouter 0.11.0 introduced the unified Flutter routing surface with nested views, guards, route state hooks, and runnable examples.
Breaking Changes #
- None.
What's New #
Flutter routing API
- Added the unified routing API with guards, data loaders, named routes,
Outlet-based nested views, and declarativeLinknavigation. - Added route scope hooks for location, params, query, and typed route state access.
- Added Flutter router integration and runnable Quickstart and Advanced demos.
Docs and tests
- Revamped the package README with Quick Start, Core Concepts, and API guidance.
- Added comprehensive unit and widget coverage for guards,
Outlet,URLSearchParams, and routing flows. - Added CI workflow for Flutter analysis and tests.
Migration note #
- No migration is required for this release.