unrouter_core 0.1.0 copy "unrouter_core: ^0.1.0" to clipboard
unrouter_core: ^0.1.0 copied to clipboard

Platform-agnostic routing core for matching, guards, params, and query helpers.

Unrouter Core #

Test pub dart license

Core routing primitives for matching, navigation, guards, params, query helpers, and route metadata.

Install #

dart pub add unrouter_core

Quick Start #

import 'package:unrouter_core/unrouter_core.dart';
import 'package:unstory/unstory.dart';

final router = createRouter<String>(
  history: MemoryHistory(initialEntries: [HistoryLocation(Uri(path: '/'))]),
  routes: const [
    RouteNode<String>(path: '/', view: homeView),
    RouteNode<String>(path: '/users/:id', name: 'user', view: userView),
  ],
);

String homeView() => 'home';
String userView() => 'user';

Use this package when you are building on top of the routing engine itself.

This package does not render UI. For Flutter and Nocterm packages, see flutter_unrouter and nocterm_unrouter.

0
likes
160
points
--
downloads

Documentation

API reference

Publisher

verified publishermedz.dev

Platform-agnostic routing core for matching, guards, params, and query helpers.

Repository (GitHub)
View/report issues

Topics

#router #navigation #dart #url

Funding

Consider supporting this project:

github.com

License

MIT (license)

Dependencies

ht, roux, unstory

More

Packages that depend on unrouter_core