Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue disqus plugin issue #318

Merged
merged 2 commits into from
Nov 30, 2017
Merged

Conversation

njleonzhang
Copy link
Contributor

@njleonzhang njleonzhang commented Nov 29, 2017

fix #317, disqus plugin make page refresh continuously.

location.href = location.href.replace('/-/', '/#/')

如果打开的是根目录,就会出现/ 会被route改成/#/,然后这句话由把href改回/无限循环了。
我简单做了个保护。。。单由于不太理解这句话的含义,所以也不知道这样改有没有副作用。我在我的环境里没测试出问题。

fix docsifyjs#317, disqus plugin make page refresh continuously.
@QingWei-Li
Copy link
Member

QingWei-Li commented Nov 30, 2017

emmm 因为 disqus 不支持 hashRouter 所以传过去的参数我写的是 /-/,点链接跳过来我再强转成 /#/...

@QingWei-Li QingWei-Li merged commit 041b33e into docsifyjs:master Nov 30, 2017
@njleonzhang
Copy link
Contributor Author

点链接跳过来, 你指的是disqus那边的链接么?大概明白了啊,呵呵

@njleonzhang njleonzhang deleted the patch-2 branch November 30, 2017 01:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants