Skip to content

Commit aba7bd1

Browse files
committed
fix(docs): Remove URL entirely if no parmas are set
1 parent 9e9a715 commit aba7bd1

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

projects/ngqp-demo/src/app/test-router-adapter.service.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,8 @@ export class TestRouterAdapter implements RouterAdapter {
8080
this.appendToSearchParams(urlSearchParams, paramName, value);
8181
});
8282

83-
this.url = '?' + urlSearchParams.toString();
83+
const url = urlSearchParams.toString();
84+
this.url = url.length !== 0 ? `?${url}` : '';
8485
}
8586

8687
private get params(): Params {

0 commit comments

Comments
 (0)