FLUTTER ECOSYSTEM

shelf_router

A convenient request router for the shelf web-framework, with support for URL-parameters, nested routers and routers generated from source annotations.

Latest version
1.1.4
30-day downloads
255.8K
Likes
319
Pub points
160

Package Overview

Selection guidance generated from public package information. For reference only.

Overview

Shelf Router is a lightweight, expressive routing library for the Shelf web framework, enabling developers to define HTTP routes with support for URL parameters, nested routers, and compile-time route generation via source annotations. It simplifies request handling by mapping paths to handlers with clean syntax and improved organization. Ideal for building scalable backend services in Dart applications across multiple platforms.

Use cases
  • Building RESTful APIs
  • Handling dynamic URL routes
  • Creating modular backend services
  • Generating routes from annotations
  • Integrating with Shelf-based servers
Key features
  • URL parameter support
  • Nested router composition
  • Source annotation-based route generation
  • Clean, readable route definitions
  • Seamless integration with Shelf
Suitable for
  • Dart backend developers
  • API service builders
  • Cross-platform server apps
  • Shelf framework users
  • Projects needing structured routing
Considerations
  • Requires Shelf framework
  • Limited to Dart server environments
  • Annotation processing needs build step
  • Not suitable for client-side routing
  • Dependent on build_runner for code generation
Supported platformsAndroidiOSWebmacOSWindowsLinux

Install package

flutter pub add shelf_router

Categories

Source repository

Related projects

Rankings