Skip to content
This repository was archived by the owner on Jun 11, 2022. It is now read-only.

Commit 01732fa

Browse files
committed
fix pathname
1 parent bbd298a commit 01732fa

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ Example <https://github.com/MiniValine/docs/blob/main/en/index.html>
1111
window.$docsify = {
1212
//...
1313
MiniValine: {
14+
docPath: 'full', // If not root,It is needed.
1415
appId: '<APP_ID>',
1516
appKey: '<APP_Key>',
16-
//More Options https://github.com/MiniValine/MiniValine#options
17+
//More Options https://minivaline.github.io/docs/en/#/Options except [el]
1718
}
1819
//...
1920
}

dist/docsify-minivaline.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "docsify-minivaline",
3-
"version": "1.2.0",
3+
"version": "1.3.0",
44
"description": "MiniValine for docsify",
55
"main": "dist/minivaline.min.js",
66
"scripts": {

src/main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ function docsifyMiniValine(hook, vm) {
1010
vm.config.MiniValine = vm.config.MiniValine || {}
1111
var options = Object.assign({
1212
el: '#minivcomments',
13+
pathname: vm.config.MiniValine.docPath === 'full' ? location.pathname + location.hash.replace(/\?.+/, "") : location.hash.replace(/\?.+/, ""),
1314
}, vm.config.MiniValine)
1415
new MiniValine(options)
1516
})

0 commit comments

Comments
 (0)