docs(ssr): add ssr

This commit is contained in:
qingwei.li
2017-05-30 11:54:37 +08:00
parent 43fc8b8ab1
commit 8595c99c0b
8 changed files with 375 additions and 13 deletions

View File

@@ -51,11 +51,11 @@ export class HTML5History extends History {
path = path.slice(0, queryIndex)
}
const base = getPath(location.origin, this.getBasePath())
const base = getPath(location.origin)
const baseIndex = path.indexOf(base)
if (baseIndex > -1) {
path = path.slice(baseIndex + base.length - 1)
path = path.slice(baseIndex + base.length)
}
return {