Skip to content

Commit

Permalink
Adjust README to 2.1.3
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielSharkov committed Nov 22, 2021
1 parent 2983818 commit d49dace
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import ViewUser from './views/User'

export default new SvelteRouter({
window: window,
baseUrl: '/persistent/path',
routes: {
'home': {
path: '/',
Expand All @@ -59,6 +60,11 @@ export default new SvelteRouter({
* `window` should usually be assigned the [browser object model](https://www.w3schools.com/js/js_window.asp)
but can also be used for testing and debugging purposes.

* `basePath` is an optional field which has the same principle as the HTML
`<Base>` tag. It acts like a prefix to the paths. It's useful in cases like
hosting on GitHub Pages, where the base URL is always `https://<username>.github.io/<repo-name>`
and the base path therefor always is `/<repo-name>`.

* a route name is required to be unique and is allowed to contain
`a-z`, `A-Z`, `0-9`, `-`, `_` and `.`

Expand Down

0 comments on commit d49dace

Please sign in to comment.