Copy of @zanettin's issue from angular/router#397
When I click on a routerLink
LINK:
<a [routerLink]=" ['./RouteParamsTest', { userId : '1919', lang : 'it', token : 'jwt' }] ">Route Params Test 2</a>
CONFIG:
{ path: '/route-params-test/:userId/:lang', component: RouteParamsTest, name: 'RouteParamsTest' }
with disabled JS, this URL gets called => http://localhost:3000/route-params-test/1919/it and the query string won't appear. With activated JS everything works as expected.
The reason of the problem is here. As you can see urlParams are used only in _stringifyMatrixParams() which is called only if we have auxInstructions (see here). So if we don't have auxilary routes then urlParams will never be used. (toLinkUrl() is called here to update href of the link)
@matsko @btford @IgorMinar
Copy of @zanettin's issue from angular/router#397
When I click on a routerLink
LINK:
CONFIG:
with disabled JS, this URL gets called => http://localhost:3000/route-params-test/1919/it and the query string won't appear. With activated JS everything works as expected.
The reason of the problem is here. As you can see
urlParamsare used only in_stringifyMatrixParams()which is called only if we haveauxInstructions(see here). So if we don't have auxilary routes thenurlParamswill never be used. (toLinkUrl()is called here to updatehrefof the link)@matsko @btford @IgorMinar