-
Notifications
You must be signed in to change notification settings - Fork 178
fix: wildcard and dynamic routes #1921
Copy link
Copy link
Open
Labels
bugSomething isn't working as expectedSomething isn't working as expectedhas reproductive stepsThis issue contains detailed steps to reproduce the issueThis issue contains detailed steps to reproduce the issuep1High-priority issues at the top of the work listHigh-priority issues at the top of the work list
Metadata
Metadata
Assignees
Labels
bugSomething isn't working as expectedSomething isn't working as expectedhas reproductive stepsThis issue contains detailed steps to reproduce the issueThis issue contains detailed steps to reproduce the issuep1High-priority issues at the top of the work listHigh-priority issues at the top of the work list
Description
A route like
api/v1/games/[id]/files/[...path]should have a handler that is String id, String path.The generator spits out:
.dart_frog/server.dart:50:78: Error: Too few positional arguments: 3 required, 2 given.
..mount('/', (context) => api_v1_games_$id_files_$wildcard_path.onRequest(context,context.request.url.path));
Steps To Reproduce
Create a routes folder api/v1/games/[id]/files/[...path].dart
Expected Behavior
Support dynamic + wildcard routes.
Additional Context
dart_frog --version: 1.2.11