-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
enhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is neededquestionFurther information is requestedFurther information is requestedtriagePreliminary assesmentPreliminary assesment
Description
Wildcard Paths and Route Grouping
Summary
Introduce wildcard route matching and route grouping capabilities. This feature will allow developers to define routes with wildcard segments and group routes to apply common middleware and behaviors.
Motivation
- Simplify route definitions when multiple paths share similar structures.
- Reduce code duplication by grouping routes for common handling.
- Enhance flexibility when defining dynamic routes.
Proposed Changes
- Allow wildcard segments in route paths, e.g.,
/api/*to match all sub-paths. - Enable grouping of routes so that middleware or common settings can be applied to a set of related routes.
- Update the routing mechanism to account for these new patterns without breaking existing functionality.
Implementation Ideas
- Update the route matching logic to recognize and process wildcard segments.
- Introduce a route group construct that wraps a subset of route definitions.
- Ensure backward compatibility with current static and dynamic routes.
Impact
- Developers can define more flexible route patterns.
- Reduces redundancy in route definitions by grouping related routes.
- Provides a path toward a more modular and maintainable codebase.
Open Questions
- Should wildcards be supported at any position or only at the end of the route pattern?
- What will be the priority order between static, dynamic, and wildcard routes?
Additional Notes
This issue is intended for discussion and review before any implementation starts.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is neededquestionFurther information is requestedFurther information is requestedtriagePreliminary assesmentPreliminary assesment