@vuepress/markdown 1.8.1 → 1.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/lib/snippet.js +1 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ console.log(isRequiredPlugin(PLUGINS.HIGHLIGHT_LINES)) // false
|
|
|
22
22
|
|
|
23
23
|
Remove the specified built-in markdown-it plugin in VuePress.
|
|
24
24
|
|
|
25
|
-
It's needed to use with VuePress
|
|
25
|
+
It's needed to use with VuePress’s [Plugin API > chainMarkdown](https://vuepress.vuejs.org/plugin/option-api.html#chainmarkdown).
|
|
26
26
|
|
|
27
27
|
- **Usage**:
|
|
28
28
|
|
package/lib/snippet.js
CHANGED
|
@@ -137,7 +137,7 @@ module.exports = function snippet (md, options = {}) {
|
|
|
137
137
|
*
|
|
138
138
|
* captures: ['/path/to/file.extension', 'extension', '#region', '{meta}']
|
|
139
139
|
*/
|
|
140
|
-
const rawPathRegexp = /^(
|
|
140
|
+
const rawPathRegexp = /^(.+?(?:\.([a-z]+))?)(?:(#[\w-]+))?(?: ?({\d+(?:[,-]\d+)*}))?$/
|
|
141
141
|
|
|
142
142
|
const rawPath = state.src.slice(start, end).trim().replace(/^@/, root).trim()
|
|
143
143
|
const [filename = '', extension = '', region = '', meta = ''] = (rawPathRegexp.exec(rawPath) || []).slice(1)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vuepress/markdown",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.9.1",
|
|
4
4
|
"description": "markdown for vuepress",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"documentation",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"author": "Evan You",
|
|
23
23
|
"main": "index.js",
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@vuepress/shared-utils": "1.
|
|
25
|
+
"@vuepress/shared-utils": "1.9.1",
|
|
26
26
|
"markdown-it": "^8.4.1",
|
|
27
27
|
"markdown-it-anchor": "^5.0.2",
|
|
28
28
|
"markdown-it-chain": "^1.3.0",
|
|
@@ -39,5 +39,5 @@
|
|
|
39
39
|
"email": "chl814@foxmail.com"
|
|
40
40
|
}
|
|
41
41
|
],
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "2ffd506ca0ccc2203c3786cd80b6979d95ed9431"
|
|
43
43
|
}
|