@vuepress/plugin-shiki 2.0.0-beta.38 → 2.0.0-beta.40
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.
|
@@ -4,4 +4,4 @@ import type { HighlighterOptions } from 'shiki';
|
|
|
4
4
|
* Options of @vuepress/plugin-shiki
|
|
5
5
|
*/
|
|
6
6
|
export declare type ShikiPluginOptions = Pick<HighlighterOptions, 'theme' | 'langs'>;
|
|
7
|
-
export declare const shikiPlugin: Plugin
|
|
7
|
+
export declare const shikiPlugin: ({ theme, langs, }?: ShikiPluginOptions) => Plugin;
|
package/lib/node/shikiPlugin.js
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.shikiPlugin = void 0;
|
|
4
4
|
const shiki_1 = require("shiki");
|
|
5
|
-
const shikiPlugin = ({ theme = 'nord', langs = [], }) => ({
|
|
5
|
+
const shikiPlugin = ({ theme = 'nord', langs = [], } = {}) => ({
|
|
6
6
|
name: '@vuepress/plugin-shiki',
|
|
7
|
-
async
|
|
7
|
+
extendsMarkdown: async (md) => {
|
|
8
8
|
const highlighter = await (0, shiki_1.getHighlighter)({
|
|
9
9
|
theme,
|
|
10
10
|
langs,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vuepress/plugin-shiki",
|
|
3
|
-
"version": "2.0.0-beta.
|
|
3
|
+
"version": "2.0.0-beta.40",
|
|
4
4
|
"description": "VuePress plugin - shiki",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"vuepress-plugin",
|
|
@@ -24,16 +24,15 @@
|
|
|
24
24
|
"files": [
|
|
25
25
|
"lib"
|
|
26
26
|
],
|
|
27
|
-
"scripts": {
|
|
28
|
-
"build": "tsc -b tsconfig.build.json",
|
|
29
|
-
"clean": "rimraf lib *.tsbuildinfo"
|
|
30
|
-
},
|
|
31
27
|
"dependencies": {
|
|
32
|
-
"@vuepress/core": "2.0.0-beta.
|
|
28
|
+
"@vuepress/core": "2.0.0-beta.40",
|
|
33
29
|
"shiki": "^0.10.1"
|
|
34
30
|
},
|
|
35
31
|
"publishConfig": {
|
|
36
32
|
"access": "public"
|
|
37
33
|
},
|
|
38
|
-
"
|
|
39
|
-
|
|
34
|
+
"scripts": {
|
|
35
|
+
"build": "tsc -b tsconfig.build.json",
|
|
36
|
+
"clean": "rimraf lib *.tsbuildinfo"
|
|
37
|
+
}
|
|
38
|
+
}
|