beamer
beamer copied to clipboard
BeamGuards doesn't have full information of the target url
Describe the bug I'm trying to do some redirect from the old url to the new url with BeamGuards, for example:
- Old:
/owner-store?userId=:userId
- Redirect to:
/store/:userId
BeamGuard(
pathPatterns: [RegExp('/owner-store')],
check: (context, location) => false,
beamToNamed: (origin, target) {
final state = (target.state as BeamState);
return '/store/${state.queryParameters['userId']}';
},
),
the target state never has full information of the URI, and queryParameters returns an empty map
Beamer version:: 1.5.3
Expected behavior
The state of the target
should have all information of the URI, including query params