I have implemented routes to match query parameters in ExtJS7 with following routes code
':node:params': {
before: 'isLoggedIn',
action: 'onAction',
conditions: {
':params': '(^\\?[%a-zA-Z0-9\\-\\_\\s,&=]+)'
}
}
I have also tried with following code
':node?:params': {
before: 'isLoggedIn',
action: 'onAction'
}
in both cases, routes with query parameters are not being matched to above routes but invokes unmatchedroute
action
You can't match routes to query parameters. The Router matches based on the
window.location.hash
- the part of the URL after the#
. Query parameters are part of thewindow.location.querystring
; there is no overlap.You can parameterise routes - but not with query parameters.