(path?: string | number | null)
| 600 | path(): string; |
| 601 | path(path: string | number | null): this; |
| 602 | path(path?: string | number | null): string | this { |
| 603 | if (typeof path === 'undefined') { |
| 604 | return this.$$path; |
| 605 | } |
| 606 | |
| 607 | // null path converts to empty string. Prepend with "/" if needed. |
| 608 | path = path !== null ? path.toString() : ''; |
| 609 | path = path.charAt(0) === '/' ? path : '/' + path; |
| 610 | |
| 611 | this.$$path = path; |
| 612 | |
| 613 | this.composeUrls(); |
| 614 | return this; |
| 615 | } |
| 616 | |
| 617 | /** |
| 618 | * Retrieves a map of the search parameters of the current URL, or changes a search |
no test coverage detected