@shikijs/vitepress-twoslash 1.5.1 → 1.5.2
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/dist/index.mjs +2 -2
- package/package.json +3 -3
package/dist/index.mjs
CHANGED
|
@@ -124,7 +124,7 @@ function vPre(el) {
|
|
|
124
124
|
}
|
|
125
125
|
function renderMarkdown(md) {
|
|
126
126
|
const mdast = fromMarkdown(
|
|
127
|
-
md.replace(
|
|
127
|
+
md.replace(/\{@link ([^}]*)\}/g, "$1"),
|
|
128
128
|
// replace jsdoc links
|
|
129
129
|
{ mdastExtensions: [gfmFromMarkdown()] }
|
|
130
130
|
);
|
|
@@ -214,7 +214,7 @@ ${code.split(/\n/g).slice(0, 15).join("\n").trim()}
|
|
|
214
214
|
},
|
|
215
215
|
postprocess(html) {
|
|
216
216
|
if (this.meta.twoslash)
|
|
217
|
-
return html.replace(
|
|
217
|
+
return html.replace(/\{/g, "{");
|
|
218
218
|
}
|
|
219
219
|
};
|
|
220
220
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shikijs/vitepress-twoslash",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.5.
|
|
4
|
+
"version": "1.5.2",
|
|
5
5
|
"description": "Enable Twoslash support in VitePress",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -55,8 +55,8 @@
|
|
|
55
55
|
"twoslash": "^0.2.6",
|
|
56
56
|
"twoslash-vue": "^0.2.6",
|
|
57
57
|
"vue": "^3.4.27",
|
|
58
|
-
"@shikijs/twoslash": "1.5.
|
|
59
|
-
"shiki": "1.5.
|
|
58
|
+
"@shikijs/twoslash": "1.5.2",
|
|
59
|
+
"shiki": "1.5.2"
|
|
60
60
|
},
|
|
61
61
|
"scripts": {
|
|
62
62
|
"build": "unbuild",
|