@docusaurus/core 4.0.0-canary-6898 → 4.0.0-canary-6899
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.
|
@@ -47,14 +47,12 @@ exports.DEFAULT_STORAGE_CONFIG = {
|
|
|
47
47
|
};
|
|
48
48
|
exports.DEFAULT_FASTER_CONFIG = {
|
|
49
49
|
swcJsMinimizer: false,
|
|
50
|
-
swcHtmlMinimizer: false,
|
|
51
50
|
rspackBundler: false,
|
|
52
51
|
rspackPersistentCache: false,
|
|
53
52
|
};
|
|
54
53
|
// When using the "faster: true" shortcut
|
|
55
54
|
exports.DEFAULT_FASTER_CONFIG_TRUE = {
|
|
56
55
|
swcJsMinimizer: true,
|
|
57
|
-
swcHtmlMinimizer: true,
|
|
58
56
|
rspackBundler: true,
|
|
59
57
|
rspackPersistentCache: true,
|
|
60
58
|
};
|
|
@@ -201,7 +199,6 @@ const I18N_CONFIG_SCHEMA = utils_validation_1.Joi.object({
|
|
|
201
199
|
const FASTER_CONFIG_SCHEMA = utils_validation_1.Joi.alternatives()
|
|
202
200
|
.try(utils_validation_1.Joi.object({
|
|
203
201
|
swcJsMinimizer: utils_validation_1.Joi.boolean(),
|
|
204
|
-
swcHtmlMinimizer: utils_validation_1.Joi.boolean(),
|
|
205
202
|
rspackBundler: utils_validation_1.Joi.boolean(),
|
|
206
203
|
rspackPersistentCache: utils_validation_1.Joi.boolean(),
|
|
207
204
|
swcJsLoader: utils_validation_1.Joi.any()
|
package/lib/ssg/ssgParams.d.ts
CHANGED
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import type { Manifest } from 'react-loadable-ssr-addon-v5-slorber';
|
|
8
8
|
import type { Props } from '@docusaurus/types';
|
|
9
|
-
import type { HtmlMinifierType } from '@docusaurus/bundler';
|
|
10
9
|
export type SSGParams = {
|
|
11
10
|
trailingSlash: boolean | undefined;
|
|
12
11
|
manifest: Manifest;
|
|
@@ -17,7 +16,6 @@ export type SSGParams = {
|
|
|
17
16
|
baseUrl: string;
|
|
18
17
|
noIndex: boolean;
|
|
19
18
|
DOCUSAURUS_VERSION: string;
|
|
20
|
-
htmlMinifierType: HtmlMinifierType;
|
|
21
19
|
serverBundlePath: string;
|
|
22
20
|
ssgTemplateContent: string;
|
|
23
21
|
};
|
package/lib/ssg/ssgParams.js
CHANGED
|
@@ -26,9 +26,6 @@ async function createSSGParams({ props, serverBundlePath, clientManifestPath, })
|
|
|
26
26
|
noIndex: props.siteConfig.noIndex,
|
|
27
27
|
DOCUSAURUS_VERSION: utils_1.DOCUSAURUS_VERSION,
|
|
28
28
|
serverBundlePath,
|
|
29
|
-
htmlMinifierType: props.siteConfig.future.faster.swcHtmlMinimizer
|
|
30
|
-
? 'swc'
|
|
31
|
-
: 'terser',
|
|
32
29
|
};
|
|
33
30
|
// Useless but ensures that SSG params remain serializable
|
|
34
31
|
return structuredClone(params);
|
package/lib/ssg/ssgRenderer.js
CHANGED
|
@@ -41,9 +41,7 @@ async function loadSSGRenderer({ params, }) {
|
|
|
41
41
|
logger_1.PerfLogger.async('Load App renderer', () => loadAppRenderer({
|
|
42
42
|
serverBundlePath: params.serverBundlePath,
|
|
43
43
|
})),
|
|
44
|
-
logger_1.PerfLogger.async('Load HTML minifier', () => (0, bundler_1.getHtmlMinifier)({
|
|
45
|
-
type: params.htmlMinifierType,
|
|
46
|
-
})),
|
|
44
|
+
logger_1.PerfLogger.async('Load HTML minifier', () => (0, bundler_1.getHtmlMinifier)({ type: 'swc' })),
|
|
47
45
|
logger_1.PerfLogger.async('Compile SSG template', () => (0, ssgTemplate_1.compileSSGTemplate)(params.ssgTemplateContent)),
|
|
48
46
|
]);
|
|
49
47
|
return {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@docusaurus/core",
|
|
3
3
|
"description": "Easy to Maintain Open Source Documentation Websites",
|
|
4
|
-
"version": "4.0.0-canary-
|
|
4
|
+
"version": "4.0.0-canary-6899",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -33,15 +33,15 @@
|
|
|
33
33
|
"url": "https://github.com/facebook/docusaurus/issues"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@docusaurus/babel": "4.0.0-canary-
|
|
37
|
-
"@docusaurus/bundler": "4.0.0-canary-
|
|
38
|
-
"@docusaurus/fs": "4.0.0-canary-
|
|
39
|
-
"@docusaurus/glob": "4.0.0-canary-
|
|
40
|
-
"@docusaurus/logger": "4.0.0-canary-
|
|
41
|
-
"@docusaurus/mdx-loader": "4.0.0-canary-
|
|
42
|
-
"@docusaurus/utils": "4.0.0-canary-
|
|
43
|
-
"@docusaurus/utils-common": "4.0.0-canary-
|
|
44
|
-
"@docusaurus/utils-validation": "4.0.0-canary-
|
|
36
|
+
"@docusaurus/babel": "4.0.0-canary-6899",
|
|
37
|
+
"@docusaurus/bundler": "4.0.0-canary-6899",
|
|
38
|
+
"@docusaurus/fs": "4.0.0-canary-6899",
|
|
39
|
+
"@docusaurus/glob": "4.0.0-canary-6899",
|
|
40
|
+
"@docusaurus/logger": "4.0.0-canary-6899",
|
|
41
|
+
"@docusaurus/mdx-loader": "4.0.0-canary-6899",
|
|
42
|
+
"@docusaurus/utils": "4.0.0-canary-6899",
|
|
43
|
+
"@docusaurus/utils-common": "4.0.0-canary-6899",
|
|
44
|
+
"@docusaurus/utils-validation": "4.0.0-canary-6899",
|
|
45
45
|
"boxen": "^9.0.0",
|
|
46
46
|
"cli-table3": "^0.6.5",
|
|
47
47
|
"combine-promises": "^1.2.0",
|
|
@@ -72,8 +72,8 @@
|
|
|
72
72
|
"webpack-merge": "^6.0.1"
|
|
73
73
|
},
|
|
74
74
|
"devDependencies": {
|
|
75
|
-
"@docusaurus/module-type-aliases": "4.0.0-canary-
|
|
76
|
-
"@docusaurus/types": "4.0.0-canary-
|
|
75
|
+
"@docusaurus/module-type-aliases": "4.0.0-canary-6899",
|
|
76
|
+
"@docusaurus/types": "4.0.0-canary-6899",
|
|
77
77
|
"@total-typescript/shoehorn": "^0.1.2",
|
|
78
78
|
"@types/escape-html": "^1.0.4",
|
|
79
79
|
"@types/history": "^4.7.11",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"utility-types": "^3.11.0"
|
|
88
88
|
},
|
|
89
89
|
"peerDependencies": {
|
|
90
|
-
"@docusaurus/faster": "4.0.0-canary-
|
|
90
|
+
"@docusaurus/faster": "4.0.0-canary-6899",
|
|
91
91
|
"@mdx-js/react": "^3.1.1",
|
|
92
92
|
"react": "^19.3.0",
|
|
93
93
|
"react-dom": "^19.3.0"
|
|
@@ -100,5 +100,5 @@
|
|
|
100
100
|
"engines": {
|
|
101
101
|
"node": ">=24.21"
|
|
102
102
|
},
|
|
103
|
-
"gitHead": "
|
|
103
|
+
"gitHead": "72622a2308261a457ca37d1e090d3efe608558cc"
|
|
104
104
|
}
|