feat: support query string for the search, fixed #156

This commit is contained in:
qingwei.li 2017-05-06 21:11:04 +08:00
commit da75d70dee
3 changed files with 31 additions and 25 deletions

View file

@ -12,7 +12,7 @@ function replaceHash (path) {
const replaceSlug = cached(path => {
return path
.replace('#', '?id=')
.replace(/\?(\w+)=/g, (_, slug) => slug === 'id' ? '?id=' : `&${slug}=`)
// .replace(/\?(\w+)=/g, (_, slug) => slug === 'id' ? '?id=' : `&${slug}=`)
})
/**
* Normalize the current url