@rspress/shared 0.0.0-next-20240507130358 → 0.0.0-next-20240509110203
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.d.ts +1 -1
- package/dist/index.js +1 -9
- package/dist/index.mjs +1 -9
- package/dist/node-utils.js +2 -2
- package/dist/node-utils.mjs +2 -2
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
@@ -728,7 +728,7 @@ declare const MDX_REGEXP: RegExp;
|
|
728
728
|
declare const APPEARANCE_KEY = "rspress-theme-appearance";
|
729
729
|
declare const SEARCH_INDEX_NAME = "search_index";
|
730
730
|
declare const RSPRESS_TEMP_DIR = ".rspress";
|
731
|
-
declare const DEFAULT_HIGHLIGHT_LANGUAGES:
|
731
|
+
declare const DEFAULT_HIGHLIGHT_LANGUAGES: string[][];
|
732
732
|
declare const isSCM: () => boolean;
|
733
733
|
declare const isProduction: () => boolean;
|
734
734
|
declare const isDebugMode: () => boolean;
|
package/dist/index.js
CHANGED
@@ -1122,17 +1122,9 @@ var DEFAULT_HIGHLIGHT_LANGUAGES = [
|
|
1122
1122
|
["js", "javascript"],
|
1123
1123
|
["ts", "typescript"],
|
1124
1124
|
["jsx", "tsx"],
|
1125
|
-
"tsx",
|
1126
|
-
"json",
|
1127
|
-
"css",
|
1128
|
-
"scss",
|
1129
|
-
"less",
|
1130
1125
|
["xml", "xml-doc"],
|
1131
|
-
"diff",
|
1132
|
-
"yaml",
|
1133
1126
|
["md", "markdown"],
|
1134
|
-
["mdx", "tsx"]
|
1135
|
-
"bash"
|
1127
|
+
["mdx", "tsx"]
|
1136
1128
|
];
|
1137
1129
|
var isSCM = () => Boolean(process.env.BUILD_VERSION);
|
1138
1130
|
var isProduction = () => process.env.NODE_ENV === "production";
|
package/dist/index.mjs
CHANGED
@@ -1064,17 +1064,9 @@ var DEFAULT_HIGHLIGHT_LANGUAGES = [
|
|
1064
1064
|
["js", "javascript"],
|
1065
1065
|
["ts", "typescript"],
|
1066
1066
|
["jsx", "tsx"],
|
1067
|
-
"tsx",
|
1068
|
-
"json",
|
1069
|
-
"css",
|
1070
|
-
"scss",
|
1071
|
-
"less",
|
1072
1067
|
["xml", "xml-doc"],
|
1073
|
-
"diff",
|
1074
|
-
"yaml",
|
1075
1068
|
["md", "markdown"],
|
1076
|
-
["mdx", "tsx"]
|
1077
|
-
"bash"
|
1069
|
+
["mdx", "tsx"]
|
1078
1070
|
];
|
1079
1071
|
var isSCM = () => Boolean(process.env.BUILD_VERSION);
|
1080
1072
|
var isProduction = () => process.env.NODE_ENV === "production";
|
package/dist/node-utils.js
CHANGED
@@ -43,10 +43,10 @@ var import_core = require("@rsbuild/core");
|
|
43
43
|
|
44
44
|
// src/node-utils/loadFrontMatter.ts
|
45
45
|
function loadFrontMatter(source, filepath, root, outputWarning = false) {
|
46
|
-
let frontmatter = {};
|
47
46
|
let content = "";
|
47
|
+
let frontmatter = {};
|
48
48
|
try {
|
49
|
-
({ data: frontmatter
|
49
|
+
({ content, data: frontmatter } = (0, import_gray_matter.default)(source));
|
50
50
|
} catch (e) {
|
51
51
|
if (outputWarning) {
|
52
52
|
import_core.logger.warn(
|
package/dist/node-utils.mjs
CHANGED
@@ -7,10 +7,10 @@ import { logger } from "@rsbuild/core";
|
|
7
7
|
|
8
8
|
// src/node-utils/loadFrontMatter.ts
|
9
9
|
function loadFrontMatter(source, filepath, root, outputWarning = false) {
|
10
|
-
let frontmatter = {};
|
11
10
|
let content = "";
|
11
|
+
let frontmatter = {};
|
12
12
|
try {
|
13
|
-
({ data: frontmatter
|
13
|
+
({ content, data: frontmatter } = grayMatter(source));
|
14
14
|
} catch (e) {
|
15
15
|
if (outputWarning) {
|
16
16
|
logger.warn(
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@rspress/shared",
|
3
|
-
"version": "0.0.0-next-
|
3
|
+
"version": "0.0.0-next-20240509110203",
|
4
4
|
"types": "./dist/index.d.ts",
|
5
5
|
"main": "./dist/index.js",
|
6
6
|
"module": "./dist/index.mjs",
|
@@ -42,7 +42,7 @@
|
|
42
42
|
}
|
43
43
|
},
|
44
44
|
"dependencies": {
|
45
|
-
"@rsbuild/core": "0.6.
|
45
|
+
"@rsbuild/core": "0.6.13",
|
46
46
|
"unified": "^10.1.2",
|
47
47
|
"chalk": "4.1.2",
|
48
48
|
"execa": "5.1.1",
|