diff --git a/.github/workflows/tests-e2e.yml b/.github/workflows/tests-e2e.yml
index a45bdc8f8ac4..ddd86aa0f822 100644
--- a/.github/workflows/tests-e2e.yml
+++ b/.github/workflows/tests-e2e.yml
@@ -72,17 +72,17 @@ jobs:
KEEP_CONTAINER: true
- name: Install test-website project with Yarn Berry and nodeLinker = ${{ matrix.nodeLinker }}
run: |
- # we have to switch to berry first before setting the version we want
yarn set version berry
- # temporary using canary for #5342
- yarn set version canary
yarn config set nodeLinker ${{ matrix.nodeLinker }}
- yarn config set pnpMode loose
yarn config set npmRegistryServer http://localhost:4873
yarn config set unsafeHttpWhitelist --json '["localhost"]'
yarn config set enableGlobalCache true
+ # Patch package so that peer deps are provided. This has been fixed in terser by making acorn a direct dependency
+ # TODO watch out for the next terser release. Commit: https://github.com/terser/terser/commit/05b23eeb682d732484ad51b19bf528258fd5dc2a
+ yarn config set packageExtensions --json '{"terser-webpack-plugin@*": {"dependencies": {"acorn": "^8.6.0"}}, "html-minifier-terser@*": {"dependencies": {"acorn": "^8.6.0"}}}'
+
yarn install
working-directory: ../test-website
env:
diff --git a/packages/create-docusaurus/templates/classic-typescript/package.json b/packages/create-docusaurus/templates/classic-typescript/package.json
index 37ea8c95309b..e7b63fa83000 100644
--- a/packages/create-docusaurus/templates/classic-typescript/package.json
+++ b/packages/create-docusaurus/templates/classic-typescript/package.json
@@ -18,13 +18,10 @@
"@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/preset-classic": "2.0.0-beta.9",
"@mdx-js/react": "^1.6.21",
- "@svgr/webpack": "^6.0.0",
"clsx": "^1.1.1",
- "file-loader": "^6.2.0",
"prism-react-renderer": "^1.2.1",
"react": "^17.0.1",
- "react-dom": "^17.0.1",
- "url-loader": "^4.1.1"
+ "react-dom": "^17.0.1"
},
"devDependencies": {
"@docusaurus/module-type-aliases": "2.0.0-beta.9",
diff --git a/packages/create-docusaurus/templates/classic/package.json b/packages/create-docusaurus/templates/classic/package.json
index c0fcc74fe1f8..9970b01e1b5a 100644
--- a/packages/create-docusaurus/templates/classic/package.json
+++ b/packages/create-docusaurus/templates/classic/package.json
@@ -17,13 +17,10 @@
"@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/preset-classic": "2.0.0-beta.9",
"@mdx-js/react": "^1.6.21",
- "@svgr/webpack": "^6.0.0",
"clsx": "^1.1.1",
- "file-loader": "^6.2.0",
"prism-react-renderer": "^1.2.1",
"react": "^17.0.1",
- "react-dom": "^17.0.1",
- "url-loader": "^4.1.1"
+ "react-dom": "^17.0.1"
},
"browserslist": {
"production": [
diff --git a/packages/create-docusaurus/templates/facebook/package.json b/packages/create-docusaurus/templates/facebook/package.json
index f4f8859f8734..bd23ea78594e 100644
--- a/packages/create-docusaurus/templates/facebook/package.json
+++ b/packages/create-docusaurus/templates/facebook/package.json
@@ -21,12 +21,9 @@
"@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/preset-classic": "2.0.0-beta.9",
"@mdx-js/react": "^1.6.21",
- "@svgr/webpack": "^6.0.0",
"clsx": "^1.1.1",
- "file-loader": "^6.2.0",
"react": "^17.0.1",
- "react-dom": "^17.0.1",
- "url-loader": "^4.1.1"
+ "react-dom": "^17.0.1"
},
"devDependencies": {
"@babel/eslint-parser": "^7.16.3",
diff --git a/packages/docusaurus-mdx-loader/package.json b/packages/docusaurus-mdx-loader/package.json
index 6a8ac072604c..4b1e8b8d7702 100644
--- a/packages/docusaurus-mdx-loader/package.json
+++ b/packages/docusaurus-mdx-loader/package.json
@@ -20,7 +20,6 @@
"dependencies": {
"@babel/parser": "^7.16.4",
"@babel/traverse": "^7.16.3",
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@mdx-js/mdx": "^1.6.21",
"@mdx-js/react": "^1.6.21",
@@ -32,6 +31,7 @@
"mdast-util-to-string": "^2.0.0",
"remark-emoji": "^2.1.0",
"stringify-object": "^3.3.0",
+ "tslib": "^2.3.1",
"unist-util-visit": "^2.0.2",
"url-loader": "^4.1.1",
"webpack": "^5.61.0"
diff --git a/packages/docusaurus-mdx-loader/src/index.ts b/packages/docusaurus-mdx-loader/src/index.ts
index 2ffb0e415d3c..a37256db8aa2 100644
--- a/packages/docusaurus-mdx-loader/src/index.ts
+++ b/packages/docusaurus-mdx-loader/src/index.ts
@@ -13,6 +13,7 @@ import {
parseFrontMatter,
parseMarkdownContentTitle,
escapePath,
+ getFileLoaderUtils,
} from '@docusaurus/utils';
import stringifyObject from 'stringify-object';
import headings from './remark/headings';
@@ -20,7 +21,6 @@ import toc from './remark/toc';
import unwrapMdxCodeBlocks from './remark/unwrapMdxCodeBlocks';
import transformImage from './remark/transformImage';
import transformLinks from './remark/transformLinks';
-import {getFileLoaderUtils} from '@docusaurus/core/lib/webpack/utils';
import type {RemarkAndRehypePluginOptions} from '@docusaurus/mdx-loader';
import type {LoaderContext} from 'webpack';
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/__snapshots__/index.test.ts.snap
index dd2e80abfc26..257aa421a2b0 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/__snapshots__/index.test.ts.snap
+++ b/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/__snapshots__/index.test.ts.snap
@@ -12,17 +12,17 @@ exports[`transformImage plugin pathname protocol 1`] = `
exports[`transformImage plugin transform md images to 1`] = `
"![img](https://example.com/img.png)
-
+
-
+
-
+
-
+
-
+
-
+
## Heading
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/index.test.ts b/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/index.test.ts
index 2e2c06aba3da..fec6f2980bea 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/index.test.ts
+++ b/packages/docusaurus-mdx-loader/src/remark/transformImage/__tests__/index.test.ts
@@ -11,6 +11,7 @@ import mdx from 'remark-mdx';
import vfile from 'to-vfile';
import plugin from '../index';
import headings from '../../headings/index';
+import {posixPath} from '@docusaurus/utils';
const processFixture = async (name, options) => {
const filePath = path.join(__dirname, `__fixtures__/${name}.md`);
@@ -21,7 +22,9 @@ const processFixture = async (name, options) => {
.use(plugin, {...options, filePath})
.process(file);
- return result.toString();
+ return result
+ .toString()
+ .replace(new RegExp(posixPath(process.cwd()), 'g'), '[CWD]');
};
const staticDirs = [
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts
index 5eb126003978..f72a6442124c 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts
+++ b/packages/docusaurus-mdx-loader/src/remark/transformImage/index.ts
@@ -10,11 +10,11 @@ import path from 'path';
import url from 'url';
import fs from 'fs-extra';
import escapeHtml from 'escape-html';
-import {getFileLoaderUtils} from '@docusaurus/core/lib/webpack/utils';
import {
posixPath,
escapePath,
toMessageRelativeFilePath,
+ getFileLoaderUtils,
} from '@docusaurus/utils';
import type {Plugin, Transformer} from 'unified';
import type {Image, Literal} from 'mdast';
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap
index 4b6b4d89a5db..3d3d22787a86 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap
+++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/__snapshots__/index.test.ts.snap
@@ -10,13 +10,13 @@ exports[`transformAsset plugin pathname protocol 1`] = `
exports[`transformAsset plugin transform md links to 1`] = `
"[asset](https://example.com/asset.pdf)
-
+
-asset
+asset
-asset with hash
+asset with hash
-asset
+asset
## Heading
@@ -28,20 +28,20 @@ exports[`transformAsset plugin transform md links to 1`] = `
[assets](/github/!file-loader!/assets.pdf)
-asset
+asset
-asset2
+asset2
-staticAsset.pdf
+staticAsset.pdf
-@site/static/staticAsset.pdf
+@site/static/staticAsset.pdf
-@site/static/staticAsset.pdf
+@site/static/staticAsset.pdf
-Just staticAsset.pdf, and awesome staticAsset 2.pdf 'It is really "AWESOME"', but also coded staticAsset 3.pdf
+Just staticAsset.pdf, and awesome staticAsset 2.pdf 'It is really "AWESOME"', but also coded staticAsset 3.pdf
-
+
-Stylized link to asset file
+Stylized link to asset file
"
`;
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/index.test.ts b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/index.test.ts
index b9eaa062c521..6129510b413b 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/index.test.ts
+++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/__tests__/index.test.ts
@@ -11,6 +11,7 @@ import mdx from 'remark-mdx';
import vfile from 'to-vfile';
import plugin from '..';
import transformImage from '../../transformImage';
+import {posixPath} from '@docusaurus/utils';
const processFixture = async (name: string, options?) => {
const filePath = path.join(__dirname, `__fixtures__/${name}.md`);
@@ -30,7 +31,9 @@ const processFixture = async (name: string, options?) => {
})
.process(file);
- return result.toString();
+ return result
+ .toString()
+ .replace(new RegExp(posixPath(process.cwd()), 'g'), '[CWD]');
};
describe('transformAsset plugin', () => {
diff --git a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts
index 4b2939a1593a..2f06dd6771a6 100644
--- a/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts
+++ b/packages/docusaurus-mdx-loader/src/remark/transformLinks/index.ts
@@ -9,6 +9,7 @@ import {
toMessageRelativeFilePath,
posixPath,
escapePath,
+ getFileLoaderUtils,
} from '@docusaurus/utils';
import visit from 'unist-util-visit';
import path from 'path';
@@ -16,7 +17,6 @@ import url from 'url';
import fs from 'fs-extra';
import escapeHtml from 'escape-html';
import {stringifyContent} from '../utils';
-import {getFileLoaderUtils} from '@docusaurus/core/lib/webpack/utils';
import type {Plugin, Transformer} from 'unified';
import type {Link, Literal} from 'mdast';
diff --git a/packages/docusaurus-plugin-client-redirects/package.json b/packages/docusaurus-plugin-client-redirects/package.json
index 5c61b0feb5e2..0939ebd7699e 100644
--- a/packages/docusaurus-plugin-client-redirects/package.json
+++ b/packages/docusaurus-plugin-client-redirects/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@docusaurus/utils-common": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
@@ -29,9 +28,11 @@
"tslib": "^2.3.1"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-client-redirects/src/normalizePluginOptions.ts b/packages/docusaurus-plugin-client-redirects/src/normalizePluginOptions.ts
index c312019137b9..8d3f79a4f259 100644
--- a/packages/docusaurus-plugin-client-redirects/src/normalizePluginOptions.ts
+++ b/packages/docusaurus-plugin-client-redirects/src/normalizePluginOptions.ts
@@ -7,7 +7,7 @@
import {PluginOptions, RedirectOption, UserPluginOptions} from './types';
import {Joi, PathnameSchema} from '@docusaurus/utils-validation';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
+import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
export const DefaultPluginOptions: PluginOptions = {
id: DEFAULT_PLUGIN_ID, // TODO temporary
diff --git a/packages/docusaurus-plugin-content-blog/package.json b/packages/docusaurus-plugin-content-blog/package.json
index 81ddfc2c4c57..92e4e3bab211 100644
--- a/packages/docusaurus-plugin-content-blog/package.json
+++ b/packages/docusaurus-plugin-content-blog/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/mdx-loader": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
@@ -37,9 +36,11 @@
"webpack": "^5.61.0"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-content-blog/src/index.ts b/packages/docusaurus-plugin-content-blog/src/index.ts
index c06d4bfadcda..723b048bda3a 100644
--- a/packages/docusaurus-plugin-content-blog/src/index.ts
+++ b/packages/docusaurus-plugin-content-blog/src/index.ts
@@ -16,8 +16,8 @@ import {
posixPath,
addTrailingPathSeparator,
createAbsoluteFilePathMatcher,
+ DEFAULT_PLUGIN_ID,
} from '@docusaurus/utils';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import {translateContent, getTranslationFiles} from './translations';
import {
diff --git a/packages/docusaurus-plugin-content-docs/package.json b/packages/docusaurus-plugin-content-docs/package.json
index 723fe36ab0f7..8a2017ea3e0e 100644
--- a/packages/docusaurus-plugin-content-docs/package.json
+++ b/packages/docusaurus-plugin-content-docs/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/mdx-loader": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
@@ -38,6 +37,7 @@
"webpack": "^5.61.0"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/module-type-aliases": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9",
"@types/js-yaml": "^4.0.0",
@@ -47,6 +47,7 @@
"utility-types": "^3.10.0"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts
index ea004a7302b1..a96cdf4c1875 100644
--- a/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts
+++ b/packages/docusaurus-plugin-content-docs/src/__tests__/cli.test.ts
@@ -14,7 +14,7 @@ import {
getVersionsFilePath,
getVersionedSidebarsDirPath,
} from '../versions';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
+import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
const fixtureDir = path.join(__dirname, '__fixtures__');
diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts
index 9cfbad81bf31..17d343cbd529 100644
--- a/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts
+++ b/packages/docusaurus-plugin-content-docs/src/__tests__/docs.test.ts
@@ -26,10 +26,9 @@ import type {
DocNavLink,
} from '../types';
import type {LoadContext} from '@docusaurus/types';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import {DEFAULT_OPTIONS} from '../options';
import {Optional} from 'utility-types';
-import {createSlugger, posixPath} from '@docusaurus/utils';
+import {createSlugger, posixPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
import {createSidebarsUtils} from '../sidebars/utils';
const fixtureDir = path.join(__dirname, '__fixtures__');
diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts
index 858798eb06de..e897b6afaa7b 100644
--- a/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts
+++ b/packages/docusaurus-plugin-content-docs/src/__tests__/index.test.ts
@@ -15,9 +15,8 @@ import pluginContentDocs from '../index';
import {loadContext} from '@docusaurus/core/src/server/index';
import {applyConfigureWebpack} from '@docusaurus/core/src/webpack/utils';
import type {RouteConfig} from '@docusaurus/types';
-import {posixPath} from '@docusaurus/utils';
+import {posixPath, DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
import {sortConfig} from '@docusaurus/core/src/server/plugins';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import * as cliDocs from '../cli';
import {OptionsSchema} from '../options';
diff --git a/packages/docusaurus-plugin-content-docs/src/__tests__/versions.test.ts b/packages/docusaurus-plugin-content-docs/src/__tests__/versions.test.ts
index f5a0b808c4c2..68653ddec8af 100644
--- a/packages/docusaurus-plugin-content-docs/src/__tests__/versions.test.ts
+++ b/packages/docusaurus-plugin-content-docs/src/__tests__/versions.test.ts
@@ -13,7 +13,7 @@ import {
readVersionsMetadata,
} from '../versions';
import {DEFAULT_OPTIONS} from '../options';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
+import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
import {PluginOptions, VersionMetadata} from '../types';
import type {I18n} from '@docusaurus/types';
diff --git a/packages/docusaurus-plugin-content-docs/src/cli.ts b/packages/docusaurus-plugin-content-docs/src/cli.ts
index 50fc5d20d90a..633ee74a8d19 100644
--- a/packages/docusaurus-plugin-content-docs/src/cli.ts
+++ b/packages/docusaurus-plugin-content-docs/src/cli.ts
@@ -14,7 +14,7 @@ import fs from 'fs-extra';
import path from 'path';
import type {PathOptions, SidebarOptions} from './types';
import {loadSidebarsFile, resolveSidebarPathOption} from './sidebars';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
+import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
function createVersionedSidebarFile({
siteDir,
diff --git a/packages/docusaurus-plugin-content-docs/src/index.ts b/packages/docusaurus-plugin-content-docs/src/index.ts
index ec5f4c3f9714..d5f6734cdfb5 100644
--- a/packages/docusaurus-plugin-content-docs/src/index.ts
+++ b/packages/docusaurus-plugin-content-docs/src/index.ts
@@ -7,7 +7,6 @@
import path from 'path';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import {
normalizeUrl,
docuHash,
@@ -17,6 +16,7 @@ import {
addTrailingPathSeparator,
createAbsoluteFilePathMatcher,
createSlugger,
+ DEFAULT_PLUGIN_ID,
} from '@docusaurus/utils';
import type {LoadContext, Plugin} from '@docusaurus/types';
import {loadSidebars} from './sidebars';
diff --git a/packages/docusaurus-plugin-content-docs/src/versions.ts b/packages/docusaurus-plugin-content-docs/src/versions.ts
index c1151a34f438..6389a9dad44e 100644
--- a/packages/docusaurus-plugin-content-docs/src/versions.ts
+++ b/packages/docusaurus-plugin-content-docs/src/versions.ts
@@ -21,9 +21,13 @@ import {
CURRENT_VERSION_NAME,
} from './constants';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import type {LoadContext} from '@docusaurus/types';
-import {getPluginI18nPath, normalizeUrl, posixPath} from '@docusaurus/utils';
+import {
+ getPluginI18nPath,
+ normalizeUrl,
+ posixPath,
+ DEFAULT_PLUGIN_ID,
+} from '@docusaurus/utils';
import {difference} from 'lodash';
import {resolveSidebarPathOption} from './sidebars';
diff --git a/packages/docusaurus-plugin-content-pages/package.json b/packages/docusaurus-plugin-content-pages/package.json
index 93b602635850..6b31c1874039 100644
--- a/packages/docusaurus-plugin-content-pages/package.json
+++ b/packages/docusaurus-plugin-content-pages/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/mdx-loader": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
@@ -28,9 +27,11 @@
"webpack": "^5.61.0"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-content-pages/src/index.ts b/packages/docusaurus-plugin-content-pages/src/index.ts
index 4cc5626d240e..13b9293bcd92 100644
--- a/packages/docusaurus-plugin-content-pages/src/index.ts
+++ b/packages/docusaurus-plugin-content-pages/src/index.ts
@@ -18,6 +18,7 @@ import {
Globby,
createAbsoluteFilePathMatcher,
normalizeUrl,
+ DEFAULT_PLUGIN_ID,
} from '@docusaurus/utils';
import {
LoadContext,
@@ -29,7 +30,6 @@ import {
import {Configuration} from 'webpack';
import admonitions from 'remark-admonitions';
import {PluginOptionSchema} from './pluginOptionSchema';
-import {DEFAULT_PLUGIN_ID} from '@docusaurus/core/lib/constants';
import {
PluginOptions,
diff --git a/packages/docusaurus-plugin-debug/package.json b/packages/docusaurus-plugin-debug/package.json
index d441ed77fb00..576eefd90692 100644
--- a/packages/docusaurus-plugin-debug/package.json
+++ b/packages/docusaurus-plugin-debug/package.json
@@ -18,16 +18,17 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"fs-extra": "^10.0.0",
"react-json-view": "^1.21.3",
"tslib": "^2.3.1"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-google-analytics/package.json b/packages/docusaurus-plugin-google-analytics/package.json
index 5be6bb96f74a..daf384d3eb2e 100644
--- a/packages/docusaurus-plugin-google-analytics/package.json
+++ b/packages/docusaurus-plugin-google-analytics/package.json
@@ -18,13 +18,14 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-google-gtag/package.json b/packages/docusaurus-plugin-google-gtag/package.json
index 599cf606f0ff..7684fb1679a3 100644
--- a/packages/docusaurus-plugin-google-gtag/package.json
+++ b/packages/docusaurus-plugin-google-gtag/package.json
@@ -18,13 +18,14 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-ideal-image/package.json b/packages/docusaurus-plugin-ideal-image/package.json
index 3eaf221cd55d..dcd802cc0a37 100644
--- a/packages/docusaurus-plugin-ideal-image/package.json
+++ b/packages/docusaurus-plugin-ideal-image/package.json
@@ -21,7 +21,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/lqip-loader": "2.0.0-beta.9",
"@docusaurus/responsive-loader": "1.5.0",
"@endiliey/react-ideal-image": "^0.0.11",
@@ -31,10 +30,12 @@
"webpack": "^5.61.0"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9",
"fs-extra": "^10.0.0"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-plugin-pwa/package.json b/packages/docusaurus-plugin-pwa/package.json
index 1d74bd71c1b7..246a32d06ee6 100644
--- a/packages/docusaurus-plugin-pwa/package.json
+++ b/packages/docusaurus-plugin-pwa/package.json
@@ -23,7 +23,6 @@
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.16.0",
"@babel/plugin-proposal-optional-chaining": "^7.16.0",
"@babel/preset-env": "^7.16.4",
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/theme-common": "2.0.0-beta.9",
"@docusaurus/theme-translations": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
@@ -44,6 +43,7 @@
},
"peerDependencies": {
"@babel/core": "^7.0.0",
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
}
diff --git a/packages/docusaurus-plugin-sitemap/package.json b/packages/docusaurus-plugin-sitemap/package.json
index d3e24406596f..c3f4b75f1523 100644
--- a/packages/docusaurus-plugin-sitemap/package.json
+++ b/packages/docusaurus-plugin-sitemap/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
"@docusaurus/utils-common": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
@@ -27,9 +26,11 @@
"tslib": "^2.3.1"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-preset-classic/package.json b/packages/docusaurus-preset-classic/package.json
index 4318abc74b7a..b7ad44007d0b 100644
--- a/packages/docusaurus-preset-classic/package.json
+++ b/packages/docusaurus-preset-classic/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/plugin-content-blog": "2.0.0-beta.9",
"@docusaurus/plugin-content-docs": "2.0.0-beta.9",
"@docusaurus/plugin-content-pages": "2.0.0-beta.9",
@@ -30,6 +29,7 @@
"@docusaurus/theme-search-algolia": "2.0.0-beta.9"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-theme-classic/package.json b/packages/docusaurus-theme-classic/package.json
index 3c371d2ed66c..a130cb66de86 100644
--- a/packages/docusaurus-theme-classic/package.json
+++ b/packages/docusaurus-theme-classic/package.json
@@ -23,7 +23,6 @@
"update-code-translations": "node -e 'require(\"./update-code-translations.js\").run()'"
},
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/plugin-content-blog": "2.0.0-beta.9",
"@docusaurus/plugin-content-docs": "2.0.0-beta.9",
"@docusaurus/plugin-content-pages": "2.0.0-beta.9",
@@ -56,6 +55,7 @@
"utility-types": "^3.10.0"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-theme-common/package.json b/packages/docusaurus-theme-common/package.json
index 115c70bcb33a..0e2ea9caad71 100644
--- a/packages/docusaurus-theme-common/package.json
+++ b/packages/docusaurus-theme-common/package.json
@@ -18,7 +18,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/plugin-content-blog": "2.0.0-beta.9",
"@docusaurus/plugin-content-docs": "2.0.0-beta.9",
"@docusaurus/plugin-content-pages": "2.0.0-beta.9",
@@ -35,6 +34,7 @@
"lodash": "^4.17.20"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"prism-react-renderer": "^1.2.1",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
diff --git a/packages/docusaurus-theme-live-codeblock/package.json b/packages/docusaurus-theme-live-codeblock/package.json
index e54873a6114a..839f6f18cdfc 100644
--- a/packages/docusaurus-theme-live-codeblock/package.json
+++ b/packages/docusaurus-theme-live-codeblock/package.json
@@ -17,7 +17,6 @@
},
"license": "MIT",
"dependencies": {
- "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/theme-translations": "2.0.0-beta.9",
"@docusaurus/utils-validation": "2.0.0-beta.9",
"@docusaurus/utils": "2.0.0-beta.9",
@@ -29,10 +28,12 @@
"react-live": "2.2.3"
},
"devDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"@docusaurus/types": "2.0.0-beta.9",
"@types/buble": "^0.20.1"
},
"peerDependencies": {
+ "@docusaurus/core": "2.0.0-beta.9",
"react": "^16.8.4 || ^17.0.0",
"react-dom": "^16.8.4 || ^17.0.0"
},
diff --git a/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.js b/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.js
index 92ee17f67d9a..4826a8868d64 100644
--- a/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.js
+++ b/packages/docusaurus-theme-live-codeblock/src/theme/Playground/index.js
@@ -13,7 +13,7 @@ import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
import BrowserOnly from '@docusaurus/BrowserOnly';
import usePrismTheme from '@theme/hooks/usePrismTheme';
import styles from './styles.module.css';
-import useIsBrowser from '@docusaurus/core/lib/client/exports/useIsBrowser';
+import useIsBrowser from '@docusaurus/useIsBrowser';
function Header({children}) {
return