@docusaurus/core 2.0.0-beta.8bda3b2db → 2.0.0-beta.9
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/bin/beforeCli.js +125 -0
- package/bin/docusaurus.js +36 -105
- package/lib/.tsbuildinfo +1 -1
- package/lib/babel/preset.js +1 -1
- package/lib/choosePort.js +10 -11
- package/lib/client/.tsbuildinfo +1 -1
- package/lib/client/App.js +8 -22
- package/lib/client/PendingNavigation.d.ts +24 -1
- package/lib/client/PendingNavigation.js +1 -1
- package/lib/client/baseUrlIssueBanner/BaseUrlIssueBanner.js +1 -0
- package/lib/client/docusaurus.js +0 -1
- package/lib/client/exports/BrowserOnly.js +5 -3
- package/lib/client/exports/Interpolate.js +4 -0
- package/lib/client/exports/Link.js +11 -11
- package/lib/client/exports/Translate.d.ts +2 -2
- package/lib/client/exports/Translate.js +13 -9
- package/lib/client/exports/browserContext.d.ts +11 -0
- package/lib/client/exports/browserContext.js +21 -0
- package/lib/client/exports/constants.js +1 -11
- package/lib/client/exports/{context.d.ts → docusaurusContext.d.ts} +5 -3
- package/lib/client/exports/docusaurusContext.js +25 -0
- package/lib/client/exports/useBaseUrl.js +1 -1
- package/lib/client/exports/useDocusaurusContext.js +2 -7
- package/lib/client/exports/useGlobalData.js +1 -5
- package/lib/client/exports/{context.js → useIsBrowser.d.ts} +1 -2
- package/lib/client/exports/useIsBrowser.js +11 -0
- package/lib/client/normalizeLocation.d.ts +1 -3
- package/lib/client/prefetch.js +0 -1
- package/lib/client/serverEntry.js +11 -27
- package/lib/commands/build.js +26 -23
- package/lib/commands/clear.js +2 -2
- package/lib/commands/commandUtils.js +2 -2
- package/lib/commands/deploy.js +24 -14
- package/lib/commands/external.js +4 -4
- package/lib/commands/serve.js +13 -13
- package/lib/commands/start.js +74 -72
- package/lib/commands/swizzle.js +33 -33
- package/lib/commands/writeHeadingIds.d.ts +8 -5
- package/lib/commands/writeHeadingIds.js +32 -31
- package/lib/commands/writeTranslations.js +25 -11
- package/lib/constants.d.ts +1 -0
- package/lib/constants.js +4 -1
- package/lib/server/brokenLinks.js +13 -13
- package/lib/server/config.js +4 -4
- package/lib/server/configValidation.js +4 -3
- package/lib/server/duplicateRoutes.js +2 -2
- package/lib/server/html-tags/htmlTags.js +5 -5
- package/lib/server/html-tags/index.d.ts +2 -2
- package/lib/server/html-tags/index.js +3 -3
- package/lib/server/i18n.js +4 -4
- package/lib/server/index.js +99 -62
- package/lib/server/loadSetup.js +3 -3
- package/lib/server/plugins/applyRouteTrailingSlash.d.ts +2 -1
- package/lib/server/plugins/applyRouteTrailingSlash.js +3 -3
- package/lib/server/plugins/index.d.ts +3 -4
- package/lib/server/plugins/index.js +41 -27
- package/lib/server/plugins/init.d.ts +2 -6
- package/lib/server/plugins/init.js +7 -10
- package/lib/server/plugins/pluginIds.d.ts +2 -2
- package/lib/server/plugins/pluginIds.js +2 -2
- package/lib/server/presets/index.js +4 -7
- package/lib/server/routes.js +41 -23
- package/lib/server/themes/alias.d.ts +3 -2
- package/lib/server/themes/alias.js +24 -12
- package/lib/server/themes/index.d.ts +6 -2
- package/lib/server/themes/index.js +19 -9
- package/lib/server/translations/translations.d.ts +4 -5
- package/lib/server/translations/translations.js +9 -9
- package/lib/server/translations/translationsExtractor.d.ts +2 -3
- package/lib/server/translations/translationsExtractor.js +58 -47
- package/lib/server/utils.d.ts +8 -2
- package/lib/server/utils.js +8 -10
- package/lib/server/versions/__fixtures__/dummy-plugin.d.ts +0 -0
- package/lib/server/versions/__tests/index.test.js +5 -5
- package/lib/server/versions/index.js +6 -6
- package/lib/webpack/base.js +28 -19
- package/lib/webpack/client.js +8 -17
- package/lib/webpack/plugins/CleanWebpackPlugin.js +2 -5
- package/lib/webpack/plugins/LogPlugin.js +3 -4
- package/lib/webpack/plugins/WaitPlugin.js +4 -4
- package/lib/webpack/react-dev-utils-webpack5/evalSourceMapMiddleware.d.ts +2 -0
- package/lib/webpack/react-dev-utils-webpack5/formatWebpackMessages.d.ts +5 -0
- package/lib/webpack/react-dev-utils-webpack5/formatWebpackMessages.js +1 -1
- package/lib/webpack/react-dev-utils-webpack5/webpackHotDevClient.d.ts +1 -0
- package/lib/webpack/server.js +11 -7
- package/lib/webpack/sharedModuleAliases.js +1 -1
- package/lib/webpack/utils.d.ts +2 -1
- package/lib/webpack/utils.js +28 -25
- package/package.json +45 -39
- package/tsconfig.client.json +1 -2
- package/tsconfig.json +5 -4
package/lib/webpack/server.js
CHANGED
|
@@ -7,17 +7,17 @@
|
|
|
7
7
|
*/
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
const tslib_1 = require("tslib");
|
|
10
|
-
const path_1 = tslib_1.__importDefault(require("path"));
|
|
11
|
-
const webpack_merge_1 = tslib_1.__importDefault(require("webpack-merge"));
|
|
10
|
+
const path_1 = (0, tslib_1.__importDefault)(require("path"));
|
|
11
|
+
const webpack_merge_1 = (0, tslib_1.__importDefault)(require("webpack-merge"));
|
|
12
12
|
const base_1 = require("./base");
|
|
13
|
-
const WaitPlugin_1 = tslib_1.__importDefault(require("./plugins/WaitPlugin"));
|
|
14
|
-
const LogPlugin_1 = tslib_1.__importDefault(require("./plugins/LogPlugin"));
|
|
13
|
+
const WaitPlugin_1 = (0, tslib_1.__importDefault)(require("./plugins/WaitPlugin"));
|
|
14
|
+
const LogPlugin_1 = (0, tslib_1.__importDefault)(require("./plugins/LogPlugin"));
|
|
15
15
|
const constants_1 = require("../constants");
|
|
16
16
|
// Forked for Docusaurus: https://github.com/slorber/static-site-generator-webpack-plugin
|
|
17
|
-
const static_site_generator_webpack_plugin_1 = tslib_1.__importDefault(require("@slorber/static-site-generator-webpack-plugin"));
|
|
17
|
+
const static_site_generator_webpack_plugin_1 = (0, tslib_1.__importDefault)(require("@slorber/static-site-generator-webpack-plugin"));
|
|
18
18
|
function createServerConfig({ props, onLinksCollected = () => { }, }) {
|
|
19
19
|
const { baseUrl, routesPaths, generatedFilesDir, headTags, preBodyTags, postBodyTags, ssrTemplate, siteConfig: { noIndex, trailingSlash }, } = props;
|
|
20
|
-
const config = base_1.createBaseConfig(props, true);
|
|
20
|
+
const config = (0, base_1.createBaseConfig)(props, true);
|
|
21
21
|
const routesLocation = {};
|
|
22
22
|
// Array of paths to be rendered. Relative to output directory
|
|
23
23
|
const ssgPaths = routesPaths.map((str) => {
|
|
@@ -25,7 +25,7 @@ function createServerConfig({ props, onLinksCollected = () => { }, }) {
|
|
|
25
25
|
routesLocation[ssgPath] = str;
|
|
26
26
|
return ssgPath;
|
|
27
27
|
});
|
|
28
|
-
const serverConfig = webpack_merge_1.default(config, {
|
|
28
|
+
const serverConfig = (0, webpack_merge_1.default)(config, {
|
|
29
29
|
target: `node${constants_1.NODE_MAJOR_VERSION}.${constants_1.NODE_MINOR_VERSION}`,
|
|
30
30
|
entry: {
|
|
31
31
|
main: path_1.default.resolve(__dirname, '../client/serverEntry.js'),
|
|
@@ -57,6 +57,10 @@ function createServerConfig({ props, onLinksCollected = () => { }, }) {
|
|
|
57
57
|
},
|
|
58
58
|
paths: ssgPaths,
|
|
59
59
|
preferFoldersOutput: trailingSlash,
|
|
60
|
+
// When using "new URL('file.js', import.meta.url)", Webpack will emit __filename, and this plugin will throw
|
|
61
|
+
// not sure the __filename value has any importance for this plugin, just using an empty string to avoid the error
|
|
62
|
+
// See https://github.com/facebook/docusaurus/issues/4922
|
|
63
|
+
globals: { __filename: '' },
|
|
60
64
|
}),
|
|
61
65
|
// Show compilation progress bar.
|
|
62
66
|
new LogPlugin_1.default({
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
const tslib_1 = require("tslib");
|
|
10
|
-
const module_alias_1 = tslib_1.__importDefault(require("module-alias"));
|
|
10
|
+
const module_alias_1 = (0, tslib_1.__importDefault)(require("module-alias"));
|
|
11
11
|
// The shared module aliases are module aliases that need to work in both SSR/NodeJS + Webpack
|
|
12
12
|
const SharedModuleAliases = {
|
|
13
13
|
// Useful to fix the react-loadable warning
|
package/lib/webpack/utils.d.ts
CHANGED
|
@@ -26,9 +26,10 @@ export declare const getCustomizableJSLoader: (jsLoader?: "babel" | ((isServer:
|
|
|
26
26
|
* @param config initial webpack config
|
|
27
27
|
* @param isServer indicates if this is a server webpack configuration
|
|
28
28
|
* @param jsLoader custom js loader config
|
|
29
|
+
* @param content content loaded by the plugin
|
|
29
30
|
* @returns final/ modified webpack config
|
|
30
31
|
*/
|
|
31
|
-
export declare function applyConfigureWebpack(configureWebpack: ConfigureWebpackFn, config: Configuration, isServer: boolean, jsLoader
|
|
32
|
+
export declare function applyConfigureWebpack(configureWebpack: ConfigureWebpackFn, config: Configuration, isServer: boolean, jsLoader: 'babel' | ((isServer: boolean) => RuleSetRule) | undefined, content: unknown): Configuration;
|
|
32
33
|
export declare function applyConfigurePostCss(configurePostCss: NonNullable<ConfigurePostCssFn>, config: Configuration): Configuration;
|
|
33
34
|
export declare function compile(config: Configuration[]): Promise<void>;
|
|
34
35
|
declare type AssetFolder = 'images' | 'files' | 'fonts' | 'medias';
|
package/lib/webpack/utils.js
CHANGED
|
@@ -8,15 +8,15 @@
|
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
exports.getMinimizer = exports.getHttpsConfig = exports.getFileLoaderUtils = exports.compile = exports.applyConfigurePostCss = exports.applyConfigureWebpack = exports.getCustomizableJSLoader = exports.getBabelOptions = exports.getCustomBabelConfigFilePath = exports.getStyleLoaders = void 0;
|
|
10
10
|
const tslib_1 = require("tslib");
|
|
11
|
-
const mini_css_extract_plugin_1 = tslib_1.__importDefault(require("mini-css-extract-plugin"));
|
|
11
|
+
const mini_css_extract_plugin_1 = (0, tslib_1.__importDefault)(require("mini-css-extract-plugin"));
|
|
12
12
|
const webpack_merge_1 = require("webpack-merge");
|
|
13
|
-
const webpack_1 = tslib_1.__importDefault(require("webpack"));
|
|
14
|
-
const fs_extra_1 = tslib_1.__importDefault(require("fs-extra"));
|
|
15
|
-
const terser_webpack_plugin_1 = tslib_1.__importDefault(require("terser-webpack-plugin"));
|
|
16
|
-
const css_minimizer_webpack_plugin_1 = tslib_1.__importDefault(require("css-minimizer-webpack-plugin"));
|
|
17
|
-
const path_1 = tslib_1.__importDefault(require("path"));
|
|
18
|
-
const crypto_1 = tslib_1.__importDefault(require("crypto"));
|
|
19
|
-
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
13
|
+
const webpack_1 = (0, tslib_1.__importDefault)(require("webpack"));
|
|
14
|
+
const fs_extra_1 = (0, tslib_1.__importDefault)(require("fs-extra"));
|
|
15
|
+
const terser_webpack_plugin_1 = (0, tslib_1.__importDefault)(require("terser-webpack-plugin"));
|
|
16
|
+
const css_minimizer_webpack_plugin_1 = (0, tslib_1.__importDefault)(require("css-minimizer-webpack-plugin"));
|
|
17
|
+
const path_1 = (0, tslib_1.__importDefault)(require("path"));
|
|
18
|
+
const crypto_1 = (0, tslib_1.__importDefault)(require("crypto"));
|
|
19
|
+
const chalk_1 = (0, tslib_1.__importDefault)(require("chalk"));
|
|
20
20
|
const constants_1 = require("../constants");
|
|
21
21
|
const lodash_1 = require("lodash");
|
|
22
22
|
// Utility method to get style loaders
|
|
@@ -66,7 +66,7 @@ function getStyleLoaders(isServer, cssOptions = {}) {
|
|
|
66
66
|
// https://github.com/facebook/create-react-app/issues/2677
|
|
67
67
|
ident: 'postcss',
|
|
68
68
|
plugins: [
|
|
69
|
-
// eslint-disable-next-line
|
|
69
|
+
// eslint-disable-next-line global-require
|
|
70
70
|
require('autoprefixer'),
|
|
71
71
|
],
|
|
72
72
|
},
|
|
@@ -112,7 +112,7 @@ const getCustomizableJSLoader = (jsLoader = 'babel') => ({ isServer, babelOption
|
|
|
112
112
|
: jsLoader(isServer);
|
|
113
113
|
exports.getCustomizableJSLoader = getCustomizableJSLoader;
|
|
114
114
|
// TODO remove this before end of 2021?
|
|
115
|
-
const warnBabelLoaderOnce = lodash_1.memoize(function () {
|
|
115
|
+
const warnBabelLoaderOnce = (0, lodash_1.memoize)(function () {
|
|
116
116
|
console.warn(chalk_1.default.yellow('Docusaurus plans to support multiple JS loader strategies (Babel, esbuild...): "getBabelLoader(isServer)" is now deprecated in favor of "getJSLoader({isServer})".'));
|
|
117
117
|
});
|
|
118
118
|
const getBabelLoaderDeprecated = function getBabelLoaderDeprecated(isServer, babelOptions) {
|
|
@@ -120,7 +120,7 @@ const getBabelLoaderDeprecated = function getBabelLoaderDeprecated(isServer, bab
|
|
|
120
120
|
return getDefaultBabelLoader({ isServer, babelOptions });
|
|
121
121
|
};
|
|
122
122
|
// TODO remove this before end of 2021 ?
|
|
123
|
-
const warnCacheLoaderOnce = lodash_1.memoize(function () {
|
|
123
|
+
const warnCacheLoaderOnce = (0, lodash_1.memoize)(function () {
|
|
124
124
|
console.warn(chalk_1.default.yellow('Docusaurus uses Webpack 5 and getCacheLoader() usage is now deprecated.'));
|
|
125
125
|
});
|
|
126
126
|
function getCacheLoaderDeprecated() {
|
|
@@ -133,24 +133,24 @@ function getCacheLoaderDeprecated() {
|
|
|
133
133
|
* @param config initial webpack config
|
|
134
134
|
* @param isServer indicates if this is a server webpack configuration
|
|
135
135
|
* @param jsLoader custom js loader config
|
|
136
|
+
* @param content content loaded by the plugin
|
|
136
137
|
* @returns final/ modified webpack config
|
|
137
138
|
*/
|
|
138
|
-
function applyConfigureWebpack(configureWebpack, config, isServer, jsLoader) {
|
|
139
|
+
function applyConfigureWebpack(configureWebpack, config, isServer, jsLoader, content) {
|
|
139
140
|
// Export some utility functions
|
|
140
141
|
const utils = {
|
|
141
142
|
getStyleLoaders,
|
|
142
|
-
getJSLoader: exports.getCustomizableJSLoader(jsLoader),
|
|
143
|
+
getJSLoader: (0, exports.getCustomizableJSLoader)(jsLoader),
|
|
143
144
|
getBabelLoader: getBabelLoaderDeprecated,
|
|
144
145
|
getCacheLoader: getCacheLoaderDeprecated,
|
|
145
146
|
};
|
|
146
147
|
if (typeof configureWebpack === 'function') {
|
|
147
|
-
const { mergeStrategy, ...res } = configureWebpack(config, isServer, utils);
|
|
148
|
+
const { mergeStrategy, ...res } = configureWebpack(config, isServer, utils, content);
|
|
148
149
|
if (res && typeof res === 'object') {
|
|
149
|
-
// @ts-expect-error: annoying error due to enums: https://github.com/survivejs/webpack-merge/issues/179
|
|
150
150
|
const customizeRules = mergeStrategy !== null && mergeStrategy !== void 0 ? mergeStrategy : {};
|
|
151
|
-
return webpack_merge_1.mergeWithCustomize({
|
|
152
|
-
customizeArray: webpack_merge_1.customizeArray(customizeRules),
|
|
153
|
-
customizeObject: webpack_merge_1.customizeObject(customizeRules),
|
|
151
|
+
return (0, webpack_merge_1.mergeWithCustomize)({
|
|
152
|
+
customizeArray: (0, webpack_merge_1.customizeArray)(customizeRules),
|
|
153
|
+
customizeObject: (0, webpack_merge_1.customizeObject)(customizeRules),
|
|
154
154
|
})(config, res);
|
|
155
155
|
}
|
|
156
156
|
}
|
|
@@ -175,16 +175,16 @@ function applyConfigurePostCss(configurePostCss, config) {
|
|
|
175
175
|
else if (Array.isArray(entry.use)) {
|
|
176
176
|
entry.use
|
|
177
177
|
.filter((u) => typeof u === 'object')
|
|
178
|
-
.forEach(overridePostCssOptions);
|
|
178
|
+
.forEach((rule) => overridePostCssOptions(rule));
|
|
179
179
|
}
|
|
180
180
|
}
|
|
181
|
-
(_b = (_a = config.module) === null || _a === void 0 ? void 0 : _a.rules) === null || _b === void 0 ? void 0 : _b.forEach(overridePostCssOptions);
|
|
181
|
+
(_b = (_a = config.module) === null || _a === void 0 ? void 0 : _a.rules) === null || _b === void 0 ? void 0 : _b.forEach((rule) => overridePostCssOptions(rule));
|
|
182
182
|
return config;
|
|
183
183
|
}
|
|
184
184
|
exports.applyConfigurePostCss = applyConfigurePostCss;
|
|
185
185
|
function compile(config) {
|
|
186
186
|
return new Promise((resolve, reject) => {
|
|
187
|
-
const compiler = webpack_1.default(config);
|
|
187
|
+
const compiler = (0, webpack_1.default)(config);
|
|
188
188
|
compiler.run((err, stats) => {
|
|
189
189
|
var _a;
|
|
190
190
|
if (err) {
|
|
@@ -223,8 +223,8 @@ function compile(config) {
|
|
|
223
223
|
exports.compile = compile;
|
|
224
224
|
// Inspired by https://github.com/gatsbyjs/gatsby/blob/8e6e021014da310b9cc7d02e58c9b3efe938c665/packages/gatsby/src/utils/webpack-utils.ts#L447
|
|
225
225
|
function getFileLoaderUtils() {
|
|
226
|
-
// files/images <
|
|
227
|
-
const urlLoaderLimit =
|
|
226
|
+
// files/images < urlLoaderLimit will be inlined as base64 strings directly in the html
|
|
227
|
+
const urlLoaderLimit = constants_1.WEBPACK_URL_LOADER_LIMIT;
|
|
228
228
|
// defines the path/pattern of the assets handled by webpack
|
|
229
229
|
const fileLoaderFileName = (folder) => `${constants_1.OUTPUT_STATIC_ASSETS_DIR_NAME}/${folder}/[name]-[hash].[ext]`;
|
|
230
230
|
const loaders = {
|
|
@@ -324,7 +324,7 @@ function getFileLoaderUtils() {
|
|
|
324
324
|
exports.getFileLoaderUtils = getFileLoaderUtils;
|
|
325
325
|
// Ensure the certificate and key provided are valid and if not
|
|
326
326
|
// throw an easy to debug error
|
|
327
|
-
function validateKeyAndCerts({ cert, key, keyFile, crtFile }) {
|
|
327
|
+
function validateKeyAndCerts({ cert, key, keyFile, crtFile, }) {
|
|
328
328
|
let encrypted;
|
|
329
329
|
try {
|
|
330
330
|
// publicEncrypt will throw an error with an invalid cert
|
|
@@ -390,10 +390,11 @@ function getMinimizer(useSimpleCssMinifier = false) {
|
|
|
390
390
|
// into invalid ecma 5 code. This is why the 'compress' and 'output'
|
|
391
391
|
// sections only apply transformations that are ecma 5 safe
|
|
392
392
|
// https://github.com/facebook/create-react-app/pull/4234
|
|
393
|
-
ecma:
|
|
393
|
+
ecma: 2020,
|
|
394
394
|
},
|
|
395
395
|
compress: {
|
|
396
396
|
ecma: 5,
|
|
397
|
+
// @ts-expect-error: API change in new version?
|
|
397
398
|
warnings: false,
|
|
398
399
|
},
|
|
399
400
|
mangle: {
|
|
@@ -424,10 +425,12 @@ function getMinimizer(useSimpleCssMinifier = false) {
|
|
|
424
425
|
},
|
|
425
426
|
// CleanCss options
|
|
426
427
|
{
|
|
428
|
+
// @ts-expect-error: API change in new version?
|
|
427
429
|
inline: false,
|
|
428
430
|
level: {
|
|
429
431
|
1: {
|
|
430
432
|
all: false,
|
|
433
|
+
removeWhitespace: true,
|
|
431
434
|
},
|
|
432
435
|
2: {
|
|
433
436
|
all: true,
|
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": "2.0.0-beta.
|
|
4
|
+
"version": "2.0.0-beta.9",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -31,89 +31,95 @@
|
|
|
31
31
|
"url": "https://github.com/facebook/docusaurus/issues"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@docusaurus/module-type-aliases": "2.0.0-beta.
|
|
34
|
+
"@docusaurus/module-type-aliases": "2.0.0-beta.9",
|
|
35
|
+
"@types/copy-webpack-plugin": "^8.0.1",
|
|
36
|
+
"@types/css-minimizer-webpack-plugin": "^3.0.2",
|
|
35
37
|
"@types/detect-port": "^1.3.0",
|
|
38
|
+
"@types/mini-css-extract-plugin": "^1.4.3",
|
|
36
39
|
"@types/nprogress": "^0.2.0",
|
|
40
|
+
"@types/react-dom": "^17.0.9",
|
|
41
|
+
"@types/rtl-detect": "^1.0.0",
|
|
42
|
+
"@types/serve-handler": "^6.1.1",
|
|
43
|
+
"@types/webpack-bundle-analyzer": "^4.4.1",
|
|
37
44
|
"tmp-promise": "^3.0.2"
|
|
38
45
|
},
|
|
39
46
|
"dependencies": {
|
|
40
47
|
"@babel/core": "^7.12.16",
|
|
41
48
|
"@babel/generator": "^7.12.15",
|
|
42
49
|
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
|
|
43
|
-
"@babel/plugin-transform-runtime": "^7.
|
|
44
|
-
"@babel/preset-env": "^7.
|
|
50
|
+
"@babel/plugin-transform-runtime": "^7.15.0",
|
|
51
|
+
"@babel/preset-env": "^7.15.6",
|
|
45
52
|
"@babel/preset-react": "^7.12.13",
|
|
46
53
|
"@babel/preset-typescript": "^7.12.16",
|
|
47
|
-
"@babel/runtime": "^7.
|
|
48
|
-
"@babel/runtime-corejs3": "^7.
|
|
54
|
+
"@babel/runtime": "^7.15.4",
|
|
55
|
+
"@babel/runtime-corejs3": "^7.15.4",
|
|
49
56
|
"@babel/traverse": "^7.12.13",
|
|
50
|
-
"@docusaurus/cssnano-preset": "2.0.0-beta.
|
|
51
|
-
"@docusaurus/react-loadable": "5.5.
|
|
52
|
-
"@docusaurus/types": "2.0.0-beta.
|
|
53
|
-
"@docusaurus/utils": "2.0.0-beta.
|
|
54
|
-
"@docusaurus/utils-common": "2.0.0-beta.
|
|
55
|
-
"@docusaurus/utils-validation": "2.0.0-beta.
|
|
57
|
+
"@docusaurus/cssnano-preset": "2.0.0-beta.9",
|
|
58
|
+
"@docusaurus/react-loadable": "5.5.2",
|
|
59
|
+
"@docusaurus/types": "2.0.0-beta.9",
|
|
60
|
+
"@docusaurus/utils": "2.0.0-beta.9",
|
|
61
|
+
"@docusaurus/utils-common": "2.0.0-beta.9",
|
|
62
|
+
"@docusaurus/utils-validation": "2.0.0-beta.9",
|
|
56
63
|
"@slorber/static-site-generator-webpack-plugin": "^4.0.0",
|
|
57
64
|
"@svgr/webpack": "^5.5.0",
|
|
58
|
-
"autoprefixer": "^10.
|
|
65
|
+
"autoprefixer": "^10.3.5",
|
|
59
66
|
"babel-loader": "^8.2.2",
|
|
60
67
|
"babel-plugin-dynamic-import-node": "2.3.0",
|
|
61
68
|
"boxen": "^5.0.1",
|
|
62
|
-
"chalk": "^4.1.
|
|
63
|
-
"chokidar": "^3.5.
|
|
64
|
-
"clean-css": "^5.1.
|
|
69
|
+
"chalk": "^4.1.2",
|
|
70
|
+
"chokidar": "^3.5.2",
|
|
71
|
+
"clean-css": "^5.1.5",
|
|
65
72
|
"commander": "^5.1.0",
|
|
66
|
-
"copy-webpack-plugin": "^
|
|
67
|
-
"core-js": "^3.
|
|
73
|
+
"copy-webpack-plugin": "^9.0.1",
|
|
74
|
+
"core-js": "^3.18.0",
|
|
68
75
|
"css-loader": "^5.1.1",
|
|
69
|
-
"css-minimizer-webpack-plugin": "^
|
|
70
|
-
"cssnano": "^5.0.
|
|
76
|
+
"css-minimizer-webpack-plugin": "^3.0.2",
|
|
77
|
+
"cssnano": "^5.0.8",
|
|
71
78
|
"del": "^6.0.0",
|
|
72
79
|
"detect-port": "^1.3.0",
|
|
73
80
|
"escape-html": "^1.0.3",
|
|
74
|
-
"eta": "^1.12.
|
|
75
|
-
"express": "^4.17.1",
|
|
81
|
+
"eta": "^1.12.3",
|
|
76
82
|
"file-loader": "^6.2.0",
|
|
77
83
|
"fs-extra": "^10.0.0",
|
|
78
|
-
"github-slugger": "^1.
|
|
84
|
+
"github-slugger": "^1.4.0",
|
|
79
85
|
"globby": "^11.0.2",
|
|
80
|
-
"html-minifier-terser": "^
|
|
86
|
+
"html-minifier-terser": "^6.0.2",
|
|
81
87
|
"html-tags": "^3.1.0",
|
|
82
|
-
"html-webpack-plugin": "^5.
|
|
88
|
+
"html-webpack-plugin": "^5.4.0",
|
|
83
89
|
"import-fresh": "^3.3.0",
|
|
84
90
|
"is-root": "^2.1.0",
|
|
85
91
|
"leven": "^3.1.0",
|
|
86
92
|
"lodash": "^4.17.20",
|
|
87
93
|
"mini-css-extract-plugin": "^1.6.0",
|
|
88
|
-
"module-alias": "^2.2.2",
|
|
89
94
|
"nprogress": "^0.2.0",
|
|
90
|
-
"postcss": "^8.
|
|
91
|
-
"postcss-loader": "^
|
|
95
|
+
"postcss": "^8.3.7",
|
|
96
|
+
"postcss-loader": "^6.1.1",
|
|
92
97
|
"prompts": "^2.4.1",
|
|
93
|
-
"react-dev-utils": "
|
|
98
|
+
"react-dev-utils": "12.0.0-next.47",
|
|
94
99
|
"react-error-overlay": "^6.0.9",
|
|
95
100
|
"react-helmet": "^6.1.0",
|
|
96
|
-
"react-loadable": "
|
|
101
|
+
"react-loadable": "npm:@docusaurus/react-loadable@5.5.2",
|
|
97
102
|
"react-loadable-ssr-addon-v5-slorber": "^1.0.1",
|
|
98
103
|
"react-router": "^5.2.0",
|
|
99
104
|
"react-router-config": "^5.1.1",
|
|
100
105
|
"react-router-dom": "^5.2.0",
|
|
106
|
+
"remark-admonitions": "^1.2.1",
|
|
101
107
|
"resolve-pathname": "^3.0.0",
|
|
102
|
-
"rtl-detect": "^1.0.
|
|
108
|
+
"rtl-detect": "^1.0.4",
|
|
103
109
|
"semver": "^7.3.4",
|
|
104
110
|
"serve-handler": "^6.1.3",
|
|
105
111
|
"shelljs": "^0.8.4",
|
|
106
112
|
"std-env": "^2.2.1",
|
|
107
113
|
"strip-ansi": "^6.0.0",
|
|
108
|
-
"terser-webpack-plugin": "^5.
|
|
109
|
-
"tslib": "^2.
|
|
114
|
+
"terser-webpack-plugin": "^5.2.4",
|
|
115
|
+
"tslib": "^2.3.1",
|
|
110
116
|
"update-notifier": "^5.1.0",
|
|
111
117
|
"url-loader": "^4.1.1",
|
|
112
|
-
"wait-on": "^
|
|
113
|
-
"webpack": "^5.
|
|
118
|
+
"wait-on": "^6.0.0",
|
|
119
|
+
"webpack": "^5.61.0",
|
|
114
120
|
"webpack-bundle-analyzer": "^4.4.2",
|
|
115
|
-
"webpack-dev-server": "^
|
|
116
|
-
"webpack-merge": "^5.
|
|
121
|
+
"webpack-dev-server": "^4.4.0",
|
|
122
|
+
"webpack-merge": "^5.8.0",
|
|
117
123
|
"webpackbar": "^5.0.0-3"
|
|
118
124
|
},
|
|
119
125
|
"peerDependencies": {
|
|
@@ -121,7 +127,7 @@
|
|
|
121
127
|
"react-dom": "^16.8.4 || ^17.0.0"
|
|
122
128
|
},
|
|
123
129
|
"engines": {
|
|
124
|
-
"node": ">=
|
|
130
|
+
"node": ">=14"
|
|
125
131
|
},
|
|
126
|
-
"gitHead": "
|
|
132
|
+
"gitHead": "8a491fc29ad002f90e97f5b5fe4178ac8fa0c4d7"
|
|
127
133
|
}
|
package/tsconfig.client.json
CHANGED
|
@@ -2,11 +2,10 @@
|
|
|
2
2
|
"extends": "../../tsconfig.json",
|
|
3
3
|
"compilerOptions": {
|
|
4
4
|
"incremental": true,
|
|
5
|
-
"lib": ["DOM"],
|
|
5
|
+
"lib": ["DOM", "ES2019"],
|
|
6
6
|
"module": "esnext",
|
|
7
7
|
"tsBuildInfoFile": "./lib/client/.tsbuildinfo",
|
|
8
8
|
"outDir": "lib/client",
|
|
9
|
-
"noImplicitAny": false,
|
|
10
9
|
"jsx": "react"
|
|
11
10
|
},
|
|
12
11
|
"include": ["src/client"]
|
package/tsconfig.json
CHANGED
|
@@ -2,12 +2,13 @@
|
|
|
2
2
|
"extends": "../../tsconfig.json",
|
|
3
3
|
"compilerOptions": {
|
|
4
4
|
"incremental": true,
|
|
5
|
-
"lib": ["DOM"],
|
|
5
|
+
"lib": ["DOM", "ES2019"],
|
|
6
6
|
"tsBuildInfoFile": "./lib/.tsbuildinfo",
|
|
7
7
|
"rootDir": "src",
|
|
8
8
|
"outDir": "lib",
|
|
9
|
-
"
|
|
10
|
-
"
|
|
9
|
+
"jsx": "react",
|
|
10
|
+
"allowJs": true
|
|
11
11
|
},
|
|
12
|
-
"
|
|
12
|
+
"include": ["src"],
|
|
13
|
+
"exclude": ["**/__tests__/**/*", "src/client"]
|
|
13
14
|
}
|