diff --git a/jest.config.js b/jest.config.js index 7ba7a6d544631..872ed9f01cb7f 100644 --- a/jest.config.js +++ b/jest.config.js @@ -102,6 +102,8 @@ const esModules = [ `periscopic`, `hast-util-to-estree`, `estree-util-attach-comments`, + `trim-lines`, + `estree-util-to-js`, ].join(`|`) module.exports = { diff --git a/packages/babel-plugin-remove-graphql-queries/src/__tests__/index.js b/packages/babel-plugin-remove-graphql-queries/src/__tests__/index.js index e14cb0123c10d..8814eaeefb644 100644 --- a/packages/babel-plugin-remove-graphql-queries/src/__tests__/index.js +++ b/packages/babel-plugin-remove-graphql-queries/src/__tests__/index.js @@ -521,7 +521,7 @@ describe(`babel-plugin-remove-graphql-queries`, () => { } `) expect(run).toThrowErrorMatchingInlineSnapshot( - `"unknown: BabelPluginRemoveGraphQLQueries: the \\"config\\" export must be async when using it with graphql"` + `"unknown file: BabelPluginRemoveGraphQLQueries: the \\"config\\" export must be async when using it with graphql"` ) }) }) diff --git a/packages/gatsby-cli/src/structured-errors/error-map.ts b/packages/gatsby-cli/src/structured-errors/error-map.ts index 6562eb796cd1c..4468895c810ec 100644 --- a/packages/gatsby-cli/src/structured-errors/error-map.ts +++ b/packages/gatsby-cli/src/structured-errors/error-map.ts @@ -768,6 +768,21 @@ const errors = { category: ErrorCategory.USER, docsUrl: `https://gatsby.dev/graphql-typegen`, }, + // Partial hydration rendering errors + "80000": { + text: (context): string => + stripIndents(`Building partial HTML failed${ + context.path ? ` for path "${context.path}"` : `` + } + + This can happen if interactive elements like "useEffect", "useState", "createContext" or event handlers are used in a component without declaring the "client export" directive at the top of the file. + + Consider adding "client export" to the top of your file if your component is interactive, otherwise refactor your component so it can be statically rendered with React Server Components (RSC). + `), + level: Level.ERROR, + docsUrl: `https://gatsby.dev/partial-hydration-error`, + category: ErrorCategory.USER, + }, } export type ErrorId = string | keyof typeof errors diff --git a/packages/gatsby-plugin-mdx/src/__tests__/compile-mdx.ts b/packages/gatsby-plugin-mdx/src/__tests__/compile-mdx.ts index b0c4807fded18..ed82ce886326b 100644 --- a/packages/gatsby-plugin-mdx/src/__tests__/compile-mdx.ts +++ b/packages/gatsby-plugin-mdx/src/__tests__/compile-mdx.ts @@ -28,28 +28,28 @@ describe(`compiles MDX`, () => { "metadata": Object {}, "processedMDX": "/*@jsxRuntime automatic @jsxImportSource react*/ import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + p: \\"p\\", + strong: \\"strong\\" + }, props.components), {Example} = _components; + if (!Example) _missingMdxReference(\\"Example\\", true); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Hello\\" + }), \\"/n\\", _jsxs(_components.p, { + children: [\\"This is \\", _jsx(_components.strong, { + children: \\"MDX\\" + })] + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { const {wrapper: MDXLayout} = props.components || ({}); return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - p: \\"p\\", - strong: \\"strong\\" - }, props.components), {Example} = _components; - if (!Example) _missingMdxReference(\\"Example\\", true); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Hello\\" - }), \\"/n\\", _jsxs(_components.p, { - children: [\\"This is \\", _jsx(_components.strong, { - children: \\"MDX\\" - })] - }), \\"/n\\", _jsx(Example, {})] - }); - } + children: _jsx(_createMdxContent, props) + })) : _createMdxContent(props); } export default MDXContent; function _missingMdxReference(id, component) { diff --git a/packages/gatsby-plugin-mdx/src/__tests__/gatsby-layout-loader.ts b/packages/gatsby-plugin-mdx/src/__tests__/gatsby-layout-loader.ts index a80a348a07cce..befdb1e7fe4e9 100644 --- a/packages/gatsby-plugin-mdx/src/__tests__/gatsby-layout-loader.ts +++ b/packages/gatsby-plugin-mdx/src/__tests__/gatsby-layout-loader.ts @@ -74,25 +74,25 @@ describe(`webpack loader: loads and injects Gatsby layout component`, () => { "import React from \\"react\\"; import GATSBY_COMPILED_MDX from \\"/mocked-layout.ts?contentFilePath=/mocked-content.mdx\\"; import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + p: \\"p\\" + }, props.components), {Example} = _components; + if (!Example) _missingMdxReference(\\"Example\\", true); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Layout test\\" + }), \\"/n\\", _jsx(_components.p, { + children: \\"Does it wrap?\\" + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { const {wrapper: MDXLayout} = props.components || ({}); return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - p: \\"p\\" - }, props.components), {Example} = _components; - if (!Example) _missingMdxReference(\\"Example\\", true); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Layout test\\" - }), \\"/n\\", _jsx(_components.p, { - children: \\"Does it wrap?\\" - }), \\"/n\\", _jsx(Example, {})] - }); - } + children: _jsx(_createMdxContent, props) + })) : _createMdxContent(props); } MDXContent export default function GatsbyMDXWrapper(props) { @@ -115,24 +115,24 @@ describe(`webpack loader: loads and injects Gatsby layout component`, () => { import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; import TemplateComponent from \\"./some-path\\"; const MDXLayout = TemplateComponent; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + p: \\"p\\" + }, props.components), {Example} = _components; + if (!Example) _missingMdxReference(\\"Example\\", true); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Layout test\\" + }), \\"/n\\", _jsx(_components.p, { + children: \\"Does it wrap?\\" + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { - return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - p: \\"p\\" - }, props.components), {Example} = _components; - if (!Example) _missingMdxReference(\\"Example\\", true); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Layout test\\" - }), \\"/n\\", _jsx(_components.p, { - children: \\"Does it wrap?\\" - }), \\"/n\\", _jsx(Example, {})] - }); - } + return _jsx(MDXLayout, Object.assign({}, props, { + children: _jsx(_createMdxContent, props) + })); } MDXContent export default function GatsbyMDXWrapper(props) { @@ -152,24 +152,24 @@ describe(`webpack loader: loads and injects Gatsby layout component`, () => { import GATSBY_COMPILED_MDX from \\"/mocked-layout.ts?contentFilePath=/mocked-content.mdx\\"; import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; import MDXLayout from \\"./some-path\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + p: \\"p\\" + }, props.components), {Example} = _components; + if (!Example) _missingMdxReference(\\"Example\\", true); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Layout test\\" + }), \\"/n\\", _jsx(_components.p, { + children: \\"Does it wrap?\\" + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { - return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - p: \\"p\\" - }, props.components), {Example} = _components; - if (!Example) _missingMdxReference(\\"Example\\", true); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Layout test\\" - }), \\"/n\\", _jsx(_components.p, { - children: \\"Does it wrap?\\" - }), \\"/n\\", _jsx(Example, {})] - }); - } + return _jsx(MDXLayout, Object.assign({}, props, { + children: _jsx(_createMdxContent, props) + })); } MDXContent export default function GatsbyMDXWrapper(props) { @@ -189,24 +189,24 @@ describe(`webpack loader: loads and injects Gatsby layout component`, () => { import GATSBY_COMPILED_MDX from \\"/mocked-layout.ts?contentFilePath=/mocked-content.mdx\\"; import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; import {Layout as MDXLayout} from \\"./some-path\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + p: \\"p\\" + }, props.components), {Example} = _components; + if (!Example) _missingMdxReference(\\"Example\\", true); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Layout test\\" + }), \\"/n\\", _jsx(_components.p, { + children: \\"Does it wrap?\\" + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { - return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - p: \\"p\\" - }, props.components), {Example} = _components; - if (!Example) _missingMdxReference(\\"Example\\", true); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Layout test\\" - }), \\"/n\\", _jsx(_components.p, { - children: \\"Does it wrap?\\" - }), \\"/n\\", _jsx(Example, {})] - }); - } + return _jsx(MDXLayout, Object.assign({}, props, { + children: _jsx(_createMdxContent, props) + })); } MDXContent export default function GatsbyMDXWrapper(props) { diff --git a/packages/gatsby-plugin-mdx/src/__tests__/gatsby-mdx-loader.ts b/packages/gatsby-plugin-mdx/src/__tests__/gatsby-mdx-loader.ts index 159bde513a19f..1a36b527efad4 100644 --- a/packages/gatsby-plugin-mdx/src/__tests__/gatsby-mdx-loader.ts +++ b/packages/gatsby-plugin-mdx/src/__tests__/gatsby-mdx-loader.ts @@ -51,28 +51,28 @@ describe(`webpack loader: parses MDX and transforms it into JSX`, () => { "/*@jsxRuntime automatic @jsxImportSource react*/ import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; import Example from \\"./example\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + hr: \\"hr\\", + h2: \\"h2\\", + h1: \\"h1\\", + p: \\"p\\" + }, props.components); + return _jsxs(_Fragment, { + children: [_jsx(_components.hr, {}), \\"/n\\", _jsx(_components.h2, { + children: \\"title: Some Frontmatter Data\\" + }), \\"/n\\", \\"/n\\", _jsx(_components.h1, { + children: \\"MDX test\\" + }), \\"/n\\", _jsx(_components.p, { + children: \\"Does it parse and transform?\\" + }), \\"/n\\", _jsx(Example, {})] + }); + } function MDXContent(props = {}) { const {wrapper: MDXLayout} = props.components || ({}); return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - hr: \\"hr\\", - h2: \\"h2\\", - h1: \\"h1\\", - p: \\"p\\" - }, props.components); - return _jsxs(_Fragment, { - children: [_jsx(_components.hr, {}), \\"/n\\", _jsx(_components.h2, { - children: \\"title: Some Frontmatter Data\\" - }), \\"/n\\", \\"/n\\", _jsx(_components.h1, { - children: \\"MDX test\\" - }), \\"/n\\", _jsx(_components.p, { - children: \\"Does it parse and transform?\\" - }), \\"/n\\", _jsx(Example, {})] - }); - } + children: _jsx(_createMdxContent, props) + })) : _createMdxContent(props); } export default MDXContent; " diff --git a/packages/gatsby-plugin-mdx/src/__tests__/remark-mdx-html-plugin.ts b/packages/gatsby-plugin-mdx/src/__tests__/remark-mdx-html-plugin.ts index 8f00f80c358f5..1a6d9ab6367d1 100644 --- a/packages/gatsby-plugin-mdx/src/__tests__/remark-mdx-html-plugin.ts +++ b/packages/gatsby-plugin-mdx/src/__tests__/remark-mdx-html-plugin.ts @@ -54,42 +54,43 @@ describe(`remark: support old remark plugins that add raw and html nodes`, () => }) await expect(processor.process(source)).resolves.toMatchInlineSnapshot(` - VFile { - "cwd": "", - "data": Object {}, - "history": Array [], - "messages": Array [], - "value": "/*@jsxRuntime automatic @jsxImportSource react*/ - import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; - function MDXContent(props = {}) { - const {wrapper: MDXLayout} = props.components || ({}); - return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - div: \\"div\\" - }, props.components); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Headline\\" - }), \\"/n\\", _jsx(_components.div, { - dangerouslySetInnerHTML: { - __html: \\"
\\" - } - }), \\"/n\\", _jsx(_components.div, { - dangerouslySetInnerHTML: { - __html: \\"Things from the past\\" - } - })] - }); - } - } - export default MDXContent; - ", - } - `) + VFile { + "cwd": "", + "data": Object {}, + "history": Array [], + "map": undefined, + "messages": Array [], + "value": "/*@jsxRuntime automatic @jsxImportSource react*/ + import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + div: \\"div\\" + }, props.components); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Headline\\" + }), \\"/n\\", _jsx(_components.div, { + dangerouslySetInnerHTML: { + __html: \\"
\\" + } + }), \\"/n\\", _jsx(_components.div, { + dangerouslySetInnerHTML: { + __html: \\"Things from the past\\" + } + })] + }); + } + function MDXContent(props = {}) { + const {wrapper: MDXLayout} = props.components || ({}); + return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { + children: _jsx(_createMdxContent, props) + })) : _createMdxContent(props); + } + export default MDXContent; + ", + } + `) }) it(`fails when plugin is missing but remark plugins add html/raw nodes`, async () => { const processor = createProcessor({ @@ -106,41 +107,42 @@ describe(`remark: support old remark plugins that add raw and html nodes`, () => }) await expect(processor.process(source)).resolves.toMatchInlineSnapshot(` - VFile { - "cwd": "", - "data": Object {}, - "history": Array [], - "messages": Array [], - "value": "/*@jsxRuntime automatic @jsxImportSource react*/ - import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; - function MDXContent(props = {}) { - const {wrapper: MDXLayout} = props.components || ({}); - return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { - children: _jsx(_createMdxContent, {}) - })) : _createMdxContent(); - function _createMdxContent() { - const _components = Object.assign({ - h1: \\"h1\\", - div: \\"div\\" - }, props.components); - return _jsxs(_Fragment, { - children: [_jsx(_components.h1, { - children: \\"Headline\\" - }), \\"/n\\", _jsx(_components.div, { - \\"aria-label\\": \\"some permalink\\", - className: \\"customClass\\", - children: _jsx(_components.div, { - dangerouslySetInnerHTML: { - __html: \\"/\\"/\\"\\" - } - }) - })] - }); - } - } - export default MDXContent; - ", - } - `) + VFile { + "cwd": "", + "data": Object {}, + "history": Array [], + "map": undefined, + "messages": Array [], + "value": "/*@jsxRuntime automatic @jsxImportSource react*/ + import {Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs} from \\"react/jsx-runtime\\"; + function _createMdxContent(props) { + const _components = Object.assign({ + h1: \\"h1\\", + div: \\"div\\" + }, props.components); + return _jsxs(_Fragment, { + children: [_jsx(_components.h1, { + children: \\"Headline\\" + }), \\"/n\\", _jsx(_components.div, { + \\"aria-label\\": \\"some permalink\\", + className: \\"customClass\\", + children: _jsx(_components.div, { + dangerouslySetInnerHTML: { + __html: \\"/\\"/\\"\\" + } + }) + })] + }); + } + function MDXContent(props = {}) { + const {wrapper: MDXLayout} = props.components || ({}); + return MDXLayout ? _jsx(MDXLayout, Object.assign({}, props, { + children: _jsx(_createMdxContent, props) + })) : _createMdxContent(props); + } + export default MDXContent; + ", + } + `) }) }) diff --git a/packages/gatsby-worker/src/index.ts b/packages/gatsby-worker/src/index.ts index d96e1e83710c1..adde5a869a030 100644 --- a/packages/gatsby-worker/src/index.ts +++ b/packages/gatsby-worker/src/index.ts @@ -138,7 +138,7 @@ export class WorkerPool< { // we don't need to retain these - const module: WorkerModuleExports = require(workerPath) + const module = require(workerPath) const exportNames = Object.keys(module) as Array< keyof WorkerModuleExports > diff --git a/packages/gatsby/cache-dir/gatsby-browser-entry.js b/packages/gatsby/cache-dir/gatsby-browser-entry.js index 3cce70589ebb3..844ec1c8ef0fb 100644 --- a/packages/gatsby/cache-dir/gatsby-browser-entry.js +++ b/packages/gatsby/cache-dir/gatsby-browser-entry.js @@ -5,6 +5,10 @@ import loader from "./loader" const prefetchPathname = loader.enqueue const StaticQueryContext = React.createContext({}) +let StaticQueryServerContext = null +if (React.createServerContext) { + StaticQueryServerContext = React.createServerContext(`StaticQuery`, {}) +} function StaticQueryDataRenderer({ staticQueryData, data, query, render }) { const finalData = data @@ -46,7 +50,17 @@ const useStaticQuery = query => { `Please update React and ReactDOM to 16.8.0 or later to use the useStaticQuery hook.` ) } - const context = React.useContext(StaticQueryContext) + let context + + // Can we get a better check here? + if ( + StaticQueryServerContext && + Object.keys(StaticQueryServerContext._currentValue).length + ) { + context = React.useContext(StaticQueryServerContext) + } else { + context = React.useContext(StaticQueryContext) + } // query is a stringified number like `3303882` when wrapped with graphql, If a user forgets // to wrap the query in a grqphql, then casting it to a Number results in `NaN` allowing us to @@ -103,6 +117,7 @@ export { StaticQuery, useStaticQuery, prefetchPathname, + StaticQueryServerContext, } export * from "gatsby-script" diff --git a/packages/gatsby/cache-dir/loader.js b/packages/gatsby/cache-dir/loader.js index 29728570ae4c2..323630ba3a863 100644 --- a/packages/gatsby/cache-dir/loader.js +++ b/packages/gatsby/cache-dir/loader.js @@ -1,3 +1,4 @@ +import { createFromReadableStream } from "react-server-dom-webpack" import prefetchHelper from "./prefetch" import emitter from "./emitter" import { setMatchPaths, findPath, findMatchPath } from "./find-path" @@ -79,6 +80,26 @@ const toPageResources = (pageData, component = null, head) => { } } +function waitForResponse(response) { + return new Promise(resolve => { + try { + const result = response.readRoot() + resolve(result) + } catch (err) { + if ( + Object.hasOwnProperty.call(err, `_response`) && + Object.hasOwnProperty.call(err, `_status`) + ) { + setTimeout(() => { + waitForResponse(response).then(resolve) + }, 200) + } else { + throw err + } + } + }) +} + export class BaseLoader { constructor(loadComponent, matchPaths) { // Map of pagePath -> Page. Where Page is an object with: { @@ -100,6 +121,7 @@ export class BaseLoader { this.inFlightDb = new Map() this.staticQueryDb = {} this.pageDataDb = new Map() + this.partialHydrationDb = new Map() this.isPrefetchQueueRunning = false this.prefetchQueued = [] this.prefetchTriggered = new Set() @@ -203,6 +225,64 @@ export class BaseLoader { }) } + fetchPartialHydrationJson(loadObj) { + const { pagePath, retries = 0 } = loadObj + const url = createPageDataUrl(pagePath).replace(`.json`, `-rsc.json`) + return this.memoizedGet(url).then(req => { + const { status, responseText } = req + + // Handle 200 + if (status === 200) { + try { + return Object.assign(loadObj, { + status: PageResourceStatus.Success, + payload: responseText, + }) + } catch (err) { + // continue regardless of error + } + } + + // Handle 404 + if (status === 404 || status === 200) { + // If the request was for a 404/500 page and it doesn't exist, we're done + if (pagePath === `/404.html` || pagePath === `/500.html`) { + return Object.assign(loadObj, { + status: PageResourceStatus.Error, + }) + } + + // Need some code here to cache the 404 request. In case + // multiple loadPageDataJsons result in 404s + return this.fetchPartialHydrationJson( + Object.assign(loadObj, { pagePath: `/404.html`, notFound: true }) + ) + } + + // handle 500 response (Unrecoverable) + if (status === 500) { + return this.fetchPartialHydrationJson( + Object.assign(loadObj, { + pagePath: `/500.html`, + internalServerError: true, + }) + ) + } + + // Handle everything else, including status === 0, and 503s. Should retry + if (retries < 3) { + return this.fetchPartialHydrationJson( + Object.assign(loadObj, { retries: retries + 1 }) + ) + } + + // Retried 3 times already, result is an error. + return Object.assign(loadObj, { + status: PageResourceStatus.Error, + }) + }) + } + loadPageDataJson(rawPath) { const pagePath = findPath(rawPath) if (this.pageDataDb.has(pagePath)) { @@ -219,6 +299,22 @@ export class BaseLoader { }) } + loadPartialHydrationJson(rawPath) { + const pagePath = findPath(rawPath) + if (this.partialHydrationDb.has(pagePath)) { + const pageData = this.partialHydrationDb.get(pagePath) + if (process.env.BUILD_STAGE !== `develop` || !pageData.stale) { + return Promise.resolve(pageData) + } + } + + return this.fetchPartialHydrationJson({ pagePath }).then(pageData => { + this.partialHydrationDb.set(pagePath, pageData) + + return pageData + }) + } + findMatchPath(rawPath) { return findMatchPath(rawPath) } @@ -244,117 +340,253 @@ export class BaseLoader { return this.inFlightDb.get(pagePath) } - const inFlightPromise = Promise.all([ - this.loadAppData(), - this.loadPageDataJson(pagePath), - ]).then(allData => { - const result = allData[1] - if (result.status === PageResourceStatus.Error) { - return { - status: PageResourceStatus.Error, + let inFlightPromise + if (global.hasPartialHydration) { + inFlightPromise = Promise.all([ + this.loadAppData(), + this.loadPageDataJson(pagePath), + this.loadPartialHydrationJson(pagePath), + ]).then(([appData, { payload: pageData }, result]) => { + if (result.status === PageResourceStatus.Error) { + return { + status: PageResourceStatus.Error, + } } - } - let pageData = result.payload - const { componentChunkName, staticQueryHashes = [] } = pageData - - const finalResult = {} - - // In develop we have separate chunks for template and Head components - // to enable HMR (fast refresh requires single exports). - // In production we have shared chunk with both exports. Double loadComponent here - // will be deduped by webpack runtime resulting in single request and single module - // being loaded for both `component` and `head`. - const componentChunkPromise = Promise.all([ - this.loadComponent(componentChunkName), - this.loadComponent(componentChunkName, `head`), - ]).then(([component, head]) => { - finalResult.createdAt = new Date() - let pageResources - if (!component || component instanceof Error) { - finalResult.status = PageResourceStatus.Error - finalResult.error = component - } else { + const finalResult = {} + + // In develop we have separate chunks for template and Head components + // to enable HMR (fast refresh requires single exports). + // In production we have shared chunk with both exports. Double loadComponent here + // will be deduped by webpack runtime resulting in single request and single module + // being loaded for both `component` and `head`. + const componentChunkPromise = this.loadComponent( + pageData.componentChunkName, + `head` + ).then(head => { + finalResult.createdAt = new Date() finalResult.status = PageResourceStatus.Success if (result.notFound === true) { finalResult.notFound = true } pageData = Object.assign(pageData, { - webpackCompilationHash: allData[0] - ? allData[0].webpackCompilationHash + webpackCompilationHash: appData + ? appData.webpackCompilationHash : ``, }) - pageResources = toPageResources(pageData, component, head) - } - // undefined if final result is an error - return pageResources - }) - const staticQueryBatchPromise = Promise.all( - staticQueryHashes.map(staticQueryHash => { - // Check for cache in case this static query result has already been loaded - if (this.staticQueryDb[staticQueryHash]) { - const jsonPayload = this.staticQueryDb[staticQueryHash] - return { staticQueryHash, jsonPayload } - } - - return this.memoizedGet( - `${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json` - ) - .then(req => { - const jsonPayload = JSON.parse(req.responseText) - return { staticQueryHash, jsonPayload } + const pageResources = toPageResources(pageData, null, head) + + if (result.payload && typeof result.payload === `string`) { + pageResources.partialHydration = result.payload + + const readableStream = new ReadableStream({ + start(controller) { + const te = new TextEncoder() + controller.enqueue(te.encode(result.payload)) + }, + pull(controller) { + // close on next read when queue is empty + controller.close() + }, + cancel() {}, }) - .catch(() => { - throw new Error( - `We couldn't load "${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json"` - ) + + return waitForResponse( + createFromReadableStream(readableStream) + ).then(result => { + pageResources.partialHydration = result + + return pageResources }) - }) - ).then(staticQueryResults => { - const staticQueryResultsMap = {} + } - staticQueryResults.forEach(({ staticQueryHash, jsonPayload }) => { - staticQueryResultsMap[staticQueryHash] = jsonPayload - this.staticQueryDb[staticQueryHash] = jsonPayload + // undefined if final result is an error + return pageResources }) - return staticQueryResultsMap - }) + // Necessary for head component + const staticQueryBatchPromise = Promise.all( + (pageData.staticQueryHashes || []).map(staticQueryHash => { + // Check for cache in case this static query result has already been loaded + if (this.staticQueryDb[staticQueryHash]) { + const jsonPayload = this.staticQueryDb[staticQueryHash] + return { staticQueryHash, jsonPayload } + } - return ( - Promise.all([componentChunkPromise, staticQueryBatchPromise]) - .then(([pageResources, staticQueryResults]) => { - let payload - if (pageResources) { - payload = { ...pageResources, staticQueryResults } - finalResult.payload = payload - emitter.emit(`onPostLoadPageResources`, { - page: payload, - pageResources: payload, + return this.memoizedGet( + `${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json` + ) + .then(req => { + const jsonPayload = JSON.parse(req.responseText) + return { staticQueryHash, jsonPayload } }) - } + .catch(() => { + throw new Error( + `We couldn't load "${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json"` + ) + }) + }) + ).then(staticQueryResults => { + const staticQueryResultsMap = {} - this.pageDb.set(pagePath, finalResult) + staticQueryResults.forEach(({ staticQueryHash, jsonPayload }) => { + staticQueryResultsMap[staticQueryHash] = jsonPayload + this.staticQueryDb[staticQueryHash] = jsonPayload + }) - if (finalResult.error) { + return staticQueryResultsMap + }) + + return ( + Promise.all([componentChunkPromise, staticQueryBatchPromise]) + .then(([pageResources, staticQueryResults]) => { + let payload + if (pageResources) { + payload = { + ...pageResources, + staticQueryResults: staticQueryResults, + } + finalResult.payload = payload + emitter.emit(`onPostLoadPageResources`, { + page: payload, + pageResources: payload, + }) + } + + this.pageDb.set(pagePath, finalResult) + + if (finalResult.error) { + return { + error: finalResult.error, + status: finalResult.status, + } + } + + return payload + }) + // when static-query fail to load we throw a better error + .catch(err => { return { - error: finalResult.error, - status: finalResult.status, + error: err, + status: PageResourceStatus.Error, } + }) + ) + }) + } else { + inFlightPromise = Promise.all([ + this.loadAppData(), + this.loadPageDataJson(pagePath), + ]).then(allData => { + const result = allData[1] + if (result.status === PageResourceStatus.Error) { + return { + status: PageResourceStatus.Error, + } + } + + let pageData = result.payload + const { componentChunkName, staticQueryHashes = [] } = pageData + + const finalResult = {} + + // In develop we have separate chunks for template and Head components + // to enable HMR (fast refresh requires single exports). + // In production we have shared chunk with both exports. Double loadComponent here + // will be deduped by webpack runtime resulting in single request and single module + // being loaded for both `component` and `head`. + const componentChunkPromise = Promise.all([ + this.loadComponent(componentChunkName), + this.loadComponent(componentChunkName, `head`), + ]).then(([component, head]) => { + finalResult.createdAt = new Date() + let pageResources + if (!component || component instanceof Error) { + finalResult.status = PageResourceStatus.Error + finalResult.error = component + } else { + finalResult.status = PageResourceStatus.Success + if (result.notFound === true) { + finalResult.notFound = true } + pageData = Object.assign(pageData, { + webpackCompilationHash: allData[0] + ? allData[0].webpackCompilationHash + : ``, + }) + pageResources = toPageResources(pageData, component, head) + } + // undefined if final result is an error + return pageResources + }) - return payload - }) - // when static-query fail to load we throw a better error - .catch(err => { - return { - error: err, - status: PageResourceStatus.Error, + const staticQueryBatchPromise = Promise.all( + staticQueryHashes.map(staticQueryHash => { + // Check for cache in case this static query result has already been loaded + if (this.staticQueryDb[staticQueryHash]) { + const jsonPayload = this.staticQueryDb[staticQueryHash] + return { staticQueryHash, jsonPayload } } + + return this.memoizedGet( + `${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json` + ) + .then(req => { + const jsonPayload = JSON.parse(req.responseText) + return { staticQueryHash, jsonPayload } + }) + .catch(() => { + throw new Error( + `We couldn't load "${__PATH_PREFIX__}/page-data/sq/d/${staticQueryHash}.json"` + ) + }) }) - ) - }) + ).then(staticQueryResults => { + const staticQueryResultsMap = {} + + staticQueryResults.forEach(({ staticQueryHash, jsonPayload }) => { + staticQueryResultsMap[staticQueryHash] = jsonPayload + this.staticQueryDb[staticQueryHash] = jsonPayload + }) + + return staticQueryResultsMap + }) + + return ( + Promise.all([componentChunkPromise, staticQueryBatchPromise]) + .then(([pageResources, staticQueryResults]) => { + let payload + if (pageResources) { + payload = { ...pageResources, staticQueryResults } + finalResult.payload = payload + emitter.emit(`onPostLoadPageResources`, { + page: payload, + pageResources: payload, + }) + } + + this.pageDb.set(pagePath, finalResult) + + if (finalResult.error) { + return { + error: finalResult.error, + status: finalResult.status, + } + } + + return payload + }) + // when static-query fail to load we throw a better error + .catch(err => { + return { + error: err, + status: PageResourceStatus.Error, + } + }) + ) + }) + } inFlightPromise .then(() => { @@ -499,14 +731,36 @@ export class BaseLoader { doPrefetch(pagePath) { const pageDataUrl = createPageDataUrl(pagePath) - return prefetchHelper(pageDataUrl, { - crossOrigin: `anonymous`, - as: `fetch`, - }).then(() => - // This was just prefetched, so will return a response from - // the cache instead of making another request to the server - this.loadPageDataJson(pagePath) - ) + + if (global.hasPartialHydration) { + return Promise.all([ + prefetchHelper(pageDataUrl, { + crossOrigin: `anonymous`, + as: `fetch`, + }).then(() => + // This was just prefetched, so will return a response from + // the cache instead of making another request to the server + this.loadPageDataJson(pagePath) + ), + prefetchHelper(pageDataUrl.replace(`.json`, `-rsc.json`), { + crossOrigin: `anonymous`, + as: `fetch`, + }).then(() => + // This was just prefetched, so will return a response from + // the cache instead of making another request to the server + this.loadPartialHydrationJson(pagePath) + ), + ]) + } else { + return prefetchHelper(pageDataUrl, { + crossOrigin: `anonymous`, + as: `fetch`, + }).then(() => + // This was just prefetched, so will return a response from + // the cache instead of making another request to the server + this.loadPageDataJson(pagePath) + ) + } } hovering(rawPath) { @@ -607,6 +861,7 @@ export class ProdLoader extends BaseLoader { if (result.status !== PageResourceStatus.Success) { return Promise.resolve() } + console.log({ result }) const pageData = result.payload const chunkName = pageData.componentChunkName const componentUrls = createComponentUrls(chunkName) @@ -637,6 +892,30 @@ export class ProdLoader extends BaseLoader { return data }) } + + loadPartialHydrationJson(rawPath) { + return super.loadPartialHydrationJson(rawPath).then(data => { + if (data.notFound) { + // check if html file exist using HEAD request: + // if it does we should navigate to it instead of showing 404 + return doFetch(rawPath, `HEAD`).then(req => { + if (req.status === 200) { + // page (.html file) actually exist (or we asked for 404 ) + // returning page resources status as errored to trigger + // regular browser navigation to given page + return { + status: PageResourceStatus.Error, + } + } + + // if HEAD request wasn't 200, return notFound result + // and show 404 page + return data + }) + } + return data + }) + } } let instance diff --git a/packages/gatsby/cache-dir/page-renderer.js b/packages/gatsby/cache-dir/page-renderer.js index 4c17a213dafa2..4e213e7003c71 100644 --- a/packages/gatsby/cache-dir/page-renderer.js +++ b/packages/gatsby/cache-dir/page-renderer.js @@ -1,4 +1,4 @@ -import { createElement } from "react" +import React, { Suspense, createElement } from "react" import PropTypes from "prop-types" import { apiRunner } from "./api-runner-browser" import { grabMatchParams } from "./find-path" @@ -16,13 +16,15 @@ function PageRenderer(props) { const preferDefault = m => (m && m.default) || m - const pageElement = createElement( - preferDefault(props.pageResources.component), - { + let pageElement + if (props.pageResources.partialHydration) { + pageElement = props.pageResources.partialHydration + } else { + pageElement = createElement(preferDefault(props.pageResources.component), { ...pageComponentProps, key: props.path || props.pageResources.page.path, - } - ) + }) + } const pageComponent = props.pageResources.head @@ -34,7 +36,10 @@ function PageRenderer(props) { const wrappedPage = apiRunner( `wrapPageElement`, - { element: pageElement, props: pageComponentProps }, + { + element: pageElement, + props: pageComponentProps, + }, pageElement, ({ result }) => { return { element: result, props: pageComponentProps } diff --git a/packages/gatsby/cache-dir/production-app.js b/packages/gatsby/cache-dir/production-app.js index 62e906ecf0255..7a5847bd9c606 100644 --- a/packages/gatsby/cache-dir/production-app.js +++ b/packages/gatsby/cache-dir/production-app.js @@ -75,14 +75,22 @@ apiRunnerAsync(`onClientEntry`).then(() => { {({ location }) => ( {({ pageResources, location }) => { - const staticQueryResults = getStaticQueryResults() - return ( - + if (pageResources.partialHydration) { + return ( {children} - - ) + ) + } else { + const staticQueryResults = getStaticQueryResults() + return ( + + + {children} + + + ) + } }} )} @@ -296,5 +304,7 @@ apiRunnerAsync(`onClientEntry`).then(() => { doc.addEventListener(`DOMContentLoaded`, handler, false) window.addEventListener(`load`, handler, false) } + + return }) }) diff --git a/packages/gatsby/cache-dir/static-entry.js b/packages/gatsby/cache-dir/static-entry.js index e051922f5ab0b..c1833f2190aa2 100644 --- a/packages/gatsby/cache-dir/static-entry.js +++ b/packages/gatsby/cache-dir/static-entry.js @@ -8,7 +8,7 @@ const { } = require(`react-dom/server`) const { ServerLocation, Router, isRedirect } = require(`@gatsbyjs/reach-router`) const merge = require(`deepmerge`) -const { StaticQueryContext } = require(`gatsby`) +const { StaticQueryContext, StaticQueryServerContext } = require(`gatsby`) const fs = require(`fs`) const { WritableAsPromise } = require(`./server-utils/writable-as-promise`) @@ -455,3 +455,6 @@ export default async function staticPage({ export function getPageChunk({ componentChunkName }) { return asyncRequires.components[componentChunkName]() } + +export { renderToPipeableStream } from "react-server-dom-webpack/writer.node.server" +export { StaticQueryContext, StaticQueryServerContext, React } diff --git a/packages/gatsby/package.json b/packages/gatsby/package.json index b82729056de00..f9f3bf4303265 100644 --- a/packages/gatsby/package.json +++ b/packages/gatsby/package.json @@ -37,6 +37,8 @@ "@typescript-eslint/eslint-plugin": "^4.33.0", "@typescript-eslint/parser": "^4.33.0", "@vercel/webpack-asset-relocator-loader": "^1.7.0", + "acorn-loose": "^8.3.0", + "acorn-walk": "^8.2.0", "address": "1.1.2", "anser": "^2.1.0", "autoprefixer": "^10.4.0", @@ -143,7 +145,8 @@ "query-string": "^6.14.1", "raw-loader": "^4.0.2", "react-dev-utils": "^12.0.1", - "react-refresh": "^0.14.0", + "react-refresh": "^0.9.0", + "react-server-dom-webpack": "0.0.0-experimental-c8b778b7f-20220825", "redux": "4.1.2", "redux-thunk": "^2.4.0", "resolve-from": "^5.0.0", @@ -178,6 +181,7 @@ "@babel/register": "^7.15.3", "@types/babel-core": "^6.25.7", "@types/eslint": "^8.2.1", + "@types/estree": "^1.0.0", "@types/express": "^4.17.13", "@types/express-http-proxy": "^1.6.3", "@types/micromatch": "^4.0.1", @@ -272,4 +276,4 @@ "yargs": { "boolean-negation": false } -} +} \ No newline at end of file diff --git a/packages/gatsby/src/commands/build-html.ts b/packages/gatsby/src/commands/build-html.ts index f2708f8d8c99e..a13696a4da687 100644 --- a/packages/gatsby/src/commands/build-html.ts +++ b/packages/gatsby/src/commands/build-html.ts @@ -219,6 +219,26 @@ const doBuildRenderer = async ( } } +const doBuildPartialHydrationRenderer = async ( + directory: string, + webpackConfig: webpack.Configuration, + stage: Stage +): Promise => { + const { stats, close } = await runWebpack(webpackConfig, stage, directory) + if (stats?.hasErrors()) { + reporter.panicOnBuild( + structureWebpackErrors(stage, stats.compilation.errors) + ) + } + + // render-page.js is hard coded in webpack.config + return { + rendererPath: `${directory}/${ROUTES_DIRECTORY}render-page.js`, + stats, + close, + } +} + export const buildRenderer = async ( program: IProgram, stage: Stage, @@ -231,6 +251,48 @@ export const buildRenderer = async ( return doBuildRenderer(program.directory, config, stage) } +export const buildPartialHydrationRenderer = async ( + program: IProgram, + stage: Stage, + parentSpan?: IActivity +): Promise => { + const config = await webpackConfig(program, program.directory, stage, null, { + parentSpan, + }) + + for (const rule of config.module.rules) { + if (`./test.js`.match(rule.test)) { + if (!rule.use) { + rule.use = [] + } + if (!Array.isArray(rule.use)) { + rule.use = [rule.use] + } + rule.use.push({ + loader: require.resolve( + `../utils/webpack/loaders/partial-hydration-reference-loader` + ), + }) + } + } + + // TODO add caching + config.cache = false + + config.output.path = path.join( + program.directory, + `.cache`, + `partial-hydration` + ) + + // TODO collect javascript aliases to match the partial hydration bundle + config.resolve.alias[`gatsby-plugin-image`] = require.resolve( + `gatsby-plugin-image/dist/gatsby-image.browser.modern` + ) + + return doBuildPartialHydrationRenderer(program.directory, config, stage) +} + // TODO remove after v4 release and update cloud internals export const deleteRenderer = async (rendererPath: string): Promise => { try { @@ -384,6 +446,42 @@ const renderHTMLQueue = async ( } } +const renderPartialHydrationQueue = async ( + workerPool: GatsbyWorkerPool, + activity: IActivity, + pages: Array +): Promise => { + // We need to only pass env vars that are set programmatically in gatsby-cli + // to child process. Other vars will be picked up from environment. + const envVars: Array<[string, string | undefined]> = [ + [`NODE_ENV`, process.env.NODE_ENV], + [`gatsby_executing_command`, process.env.gatsby_executing_command], + [`gatsby_log_level`, process.env.gatsby_log_level], + ] + + const segments = chunk(pages, 50) + const sessionId = Date.now() + // const { webpackCompilationHash } = store.getState() + + try { + await Promise.all( + segments.map(async pageSegment => { + await workerPool.single.renderPartialHydrationProd({ + envVars, + paths: pageSegment, + sessionId, + }) + + if (activity && activity.tick) { + activity.tick(pageSegment.length) + } + }) + ) + } catch (e) { + console.log({ e }) + } +} + class BuildHTMLError extends Error { codeFrame = `` context?: { @@ -475,8 +573,16 @@ export const buildHTML = async ({ activity: IActivity workerPool: GatsbyWorkerPool }): Promise => { - const { rendererPath } = await buildRenderer(program, stage, activity.span) + const rendererPath = `${program.directory}/${ROUTES_DIRECTORY}render-page.js` await doBuildPages(rendererPath, pagePaths, activity, workerPool, stage) + + if ( + (process.env.GATSBY_PARTIAL_HYDRATION === `true` || + process.env.GATSBY_PARTIAL_HYDRATION === `1`) && + _CFLAGS_.GATSBY_MAJOR === `5` + ) { + await renderPartialHydrationQueue(workerPool, activity, pagePaths) + } } export async function buildHTMLPagesAndDeleteStaleArtifacts({ @@ -491,7 +597,7 @@ export async function buildHTMLPagesAndDeleteStaleArtifacts({ toRegenerate: Array toDelete: Array }> { - const pageRenderer = `${program.directory}/${ROUTES_DIRECTORY}render-page.js` + const rendererPath = `${program.directory}/${ROUTES_DIRECTORY}render-page.js` buildUtils.markHtmlDirtyIfResultOfUsedStaticQueryChanged() const { toRegenerate, toDelete, toCleanupFromTrackedState } = @@ -514,7 +620,7 @@ export async function buildHTMLPagesAndDeleteStaleArtifacts({ buildHTMLActivityProgress.start() try { await doBuildPages( - pageRenderer, + rendererPath, toRegenerate, buildHTMLActivityProgress, workerPool, @@ -546,6 +652,48 @@ export async function buildHTMLPagesAndDeleteStaleArtifacts({ reporter.info(`There are no new or changed html files to build.`) } + if ( + (process.env.GATSBY_PARTIAL_HYDRATION === `true` || + process.env.GATSBY_PARTIAL_HYDRATION === `1`) && + _CFLAGS_.GATSBY_MAJOR === `5` + ) { + if (toRegenerate.length > 0) { + const buildHTMLActivityProgress = reporter.createProgress( + `Building partial HTML for pages`, + toRegenerate.length, + 0, + { + parentSpan, + } + ) + try { + buildHTMLActivityProgress.start() + await renderPartialHydrationQueue( + workerPool, + buildHTMLActivityProgress, + toRegenerate + ) + } catch (error) { + // Generic error with page path and useful stack trace, accurate code frame can be a future improvement + buildHTMLActivityProgress.panic({ + id: `80000`, + context: error.context, + error, + }) + } finally { + buildHTMLActivityProgress.end() + } + } + } + + if (_CFLAGS_.GATSBY_MAJOR !== `5` && !program.keepPageRenderer) { + try { + await deleteRenderer(rendererPath) + } catch (err) { + // pass through + } + } + if (toDelete.length > 0) { const publicDir = path.join(program.directory, `public`) const deletePageDataActivityTimer = reporter.activityTimer( diff --git a/packages/gatsby/src/commands/build.ts b/packages/gatsby/src/commands/build.ts index 1f91f0c02db0e..183e163422680 100644 --- a/packages/gatsby/src/commands/build.ts +++ b/packages/gatsby/src/commands/build.ts @@ -73,6 +73,7 @@ module.exports = async function build( // global gatsby object to use without store global.__GATSBY = { buildId: uuid.v4(), + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion root: program!.directory, } @@ -145,6 +146,7 @@ module.exports = async function build( let closeJavascriptBundleCompilation: (() => Promise) | undefined let closeHTMLBundleCompilation: (() => Promise) | undefined + let closePartialHydrationBundleCompilation: (() => Promise) | undefined let webpackAssets: Array | null = null let webpackCompilationHash: string | null = null let webpackSSRCompilationHash: string | null = null @@ -233,6 +235,34 @@ module.exports = async function build( buildSSRBundleActivityProgress.end() } + if ( + (process.env.GATSBY_PARTIAL_HYDRATION === `true` || + process.env.GATSBY_PARTIAL_HYDRATION === `1`) && + _CFLAGS_.GATSBY_MAJOR === `5` + ) { + const buildPartialHydrationBundleActivityProgress = report.activityTimer( + `Building Partial Hydration renderer`, + { parentSpan: buildSpan } + ) + buildPartialHydrationBundleActivityProgress.start() + try { + const { buildPartialHydrationRenderer } = await import(`./build-html`) + const { close } = await buildPartialHydrationRenderer( + program, + Stage.BuildHTML, + buildPartialHydrationBundleActivityProgress.span + ) + + closePartialHydrationBundleCompilation = close + + await close() + } catch (err) { + buildActivityTimer.panic(structureWebpackErrors(Stage.BuildHTML, err)) + } finally { + buildPartialHydrationBundleActivityProgress.end() + } + } + // exec outer config function for each template const pageConfigActivity = report.activityTimer(`Execute page configs`, { parentSpan: buildSpan, @@ -271,6 +301,7 @@ module.exports = async function build( await Promise.all([ closeJavascriptBundleCompilation?.(), closeHTMLBundleCompilation?.(), + closePartialHydrationBundleCompilation?.(), ]) } finally { cacheActivity.end() diff --git a/packages/gatsby/src/utils/webpack.config.js b/packages/gatsby/src/utils/webpack.config.js index 79ab9f26e1639..37d4c2ac4db0f 100644 --- a/packages/gatsby/src/utils/webpack.config.js +++ b/packages/gatsby/src/utils/webpack.config.js @@ -23,9 +23,10 @@ import { WebpackLoggingPlugin } from "./webpack/plugins/webpack-logging" import { hasES6ModuleSupport } from "./browserslist" import { builtinModules } from "module" import { shouldGenerateEngines } from "./engines-helpers" -import { major } from "semver" import { ROUTES_DIRECTORY } from "../constants" import { BabelConfigItemsCacheInvalidatorPlugin } from "./babel-loader" +import { PartialHydrationPlugin } from "./webpack/plugins/partial-hydration" +import { satisfiesSemvers } from "./flags" const FRAMEWORK_BUNDLES = [`react`, `react-dom`, `scheduler`, `prop-types`] @@ -54,6 +55,10 @@ module.exports = async ( const { assetPrefix, pathPrefix, trailingSlash } = store.getState().config const publicPath = getPublicPath({ assetPrefix, pathPrefix, ...program }) + const isPartialHydrationEnabled = + (process.env.GATSBY_PARTIAL_HYDRATION === `true` || + process.env.GATSBY_PARTIAL_HYDRATION === `1`) && + _CFLAGS_.GATSBY_MAJOR === `5` function processEnv(stage, defaultNodeEnv) { debug(`Building env for "${stage}"`) @@ -119,23 +124,6 @@ module.exports = async ( ) } - function getHmrPath() { - // ref: https://github.com/gatsbyjs/gatsby/issues/8348 - let hmrBasePath = `/` - const hmrSuffix = `__webpack_hmr&reload=true&overlay=false` - - if (process.env.GATSBY_WEBPACK_PUBLICPATH) { - const pubPath = process.env.GATSBY_WEBPACK_PUBLICPATH - if (pubPath.slice(-1) === `/`) { - hmrBasePath = pubPath - } else { - hmrBasePath = withTrailingSlash(pubPath) - } - } - - return hmrBasePath + hmrSuffix - } - debug(`Loading webpack config for stage "${stage}"`) function getOutput() { switch (stage) { @@ -231,8 +219,14 @@ module.exports = async ( // TODO Improve asset passing to pages BROWSER_ESM_ONLY: JSON.stringify(hasES6ModuleSupport(directory)), HAS_REACT_18: JSON.stringify( - major(require(`react-dom/package.json`).version) >= 18 + satisfiesSemvers({ + react: `>=18.0.0`, + }) || + satisfiesSemvers({ + react: `^0.0.0`, + }) ), + "global.hasPartialHydration": isPartialHydrationEnabled, }), plugins.virtualModules(), @@ -279,16 +273,24 @@ module.exports = async ( break } case `build-javascript`: { - configPlugins = configPlugins.concat([ - plugins.extractText({ - filename: `[name].[contenthash].css`, - chunkFilename: `[name].[contenthash].css`, - }), - // Write out stats object mapping named dynamic imports (aka page - // components) to all their async chunks. - plugins.extractStats(), - new StaticQueryMapper(store), - ]) + configPlugins = configPlugins + .concat([ + plugins.extractText({ + filename: `[name].[contenthash].css`, + chunkFilename: `[name].[contenthash].css`, + }), + // Write out stats object mapping named dynamic imports (aka page + // components) to all their async chunks. + plugins.extractStats(), + new StaticQueryMapper(store), + isPartialHydrationEnabled + ? new PartialHydrationPlugin( + `../.cache/partial-hydration/manifest.json`, + path.join(directory, `.cache`, `public-page-renderer-prod.js`) + ) + : null, + ]) + .filter(Boolean) break } case `develop-html`: @@ -388,7 +390,6 @@ module.exports = async ( }, ], }, - ] // Speedup 🏎️💨 the build! We only include transpilation of node_modules on javascript production builds @@ -447,6 +448,15 @@ module.exports = async ( break } + // TODO(v5): Remove since this is only useful during Gatsby 4 publishes + // Removes it from the client payload as it's not used there + if (_CFLAGS_.GATSBY_MAJOR !== `5`) { + configRules.push({ + test: /react-server-dom-webpack/, + use: loaders.null(), + }) + } + return { rules: configRules } } @@ -470,6 +480,7 @@ module.exports = async ( "react-lifecycles-compat": directoryPath( `.cache/react-lifecycles-compat.js` ), + "react-server-dom-webpack": getPackageRoot(`react-server-dom-webpack`), "@pmmmwh/react-refresh-webpack-plugin": getPackageRoot( `@pmmmwh/react-refresh-webpack-plugin` ), @@ -551,7 +562,6 @@ module.exports = async ( } if (stage === `build-html` || stage === `develop-html`) { - const [major, minor] = process.version.replace(`v`, ``).split(`.`) config.target = `node14.15` } else { config.target = [`web`, `es5`] @@ -598,6 +608,8 @@ module.exports = async ( if (stage === `build-html` || stage === `develop-html`) { config.optimization = { + // TODO fix our partial hydration manifest + mangleExports: !isPartialHydrationEnabled, splitChunks: { cacheGroups: { default: false, @@ -631,6 +643,7 @@ module.exports = async ( }, // if a module is bigger than 160kb from node_modules we make a separate chunk for it lib: { + // Don't split up the page chunks as they won't be loaded by gatsby anyways test(module) { return ( !isCssModule(module) && @@ -659,12 +672,24 @@ module.exports = async ( // if a chunk is used on all components we put it in commons (we need at least 2 components) minChunks: Math.max(componentsCount, 2), priority: 20, + // Don't split up the page chunks as they won't be loaded by gatsby anyways + // test: isPartialHydrationEnabled + // ? function (module, { chunkGraph }) { + // for (const chunk of chunkGraph.getModuleChunksIterable( + // module + // )) { + // if (chunk.name?.startsWith(`component---`)) { + // return false + // } + // } + + // return true + // } + // : undefined, }, // If a chunk is used in at least 2 components we create a separate chunk shared: { - test(module) { - return !isCssModule(module) - }, + test: module => isCssModule(module), name(module, chunks) { const hash = crypto .createHash(`sha1`) @@ -703,6 +728,8 @@ module.exports = async ( runtimeChunk: { name: `webpack-runtime`, }, + // TODO fix our partial hydration manifest + mangleExports: !isPartialHydrationEnabled, splitChunks, minimizer: [ // TODO: maybe this option should be noMinimize? diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/__snapshots__/partial-hydration-reference-loader.ts.snap b/packages/gatsby/src/utils/webpack/loaders/__tests__/__snapshots__/partial-hydration-reference-loader.ts.snap new file mode 100644 index 0000000000000..7141b7064a3c0 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/__snapshots__/partial-hydration-reference-loader.ts.snap @@ -0,0 +1,158 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`covers cases shown in fixtures/cjs-exports.js 1`] = ` +"export const a = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/cjs-exports.js', + name: 'a' + } +export const c = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/cjs-exports.js', + name: 'c' + }" +`; + +exports[`covers cases shown in fixtures/cjs-module-exports.js 1`] = `""`; + +exports[`covers cases shown in fixtures/esm-aggregation.js 1`] = `""`; + +exports[`covers cases shown in fixtures/esm-declaration.js 1`] = ` +"export const a = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'a' + } +export const b = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'b' + } +export const c = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'c' + } +export const d = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'd' + } +export const e = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'e' + } +export const f = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'f' + } +export const functionName = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'functionName' + } +export const ClassName = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'ClassName' + } +export const g = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'g' + } +export const foo = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'foo' + } +export const i = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'i' + } +export const j = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'j' + } +export const withJSX = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-declaration.js', + name: 'withJSX' + }" +`; + +exports[`covers cases shown in fixtures/esm-default-class-anonymous.js 1`] = ` +"export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-default-class-anonymous.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/esm-default-class-named.js 1`] = ` +"export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-default-class-named.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/esm-default-expression.js 1`] = ` +"export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-default-expression.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/esm-default-function-anonymous.js 1`] = ` +"export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-default-function-anonymous.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/esm-default-function-named.js 1`] = ` +"export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-default-function-named.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/esm-list.js 1`] = ` +"export const a = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-list.js', + name: 'a' + } +export const b = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-list.js', + name: 'b' + } +export const d = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-list.js', + name: 'd' + } +export const e = { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-list.js', + name: 'e' + } +export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: 'file://fixtures/esm-list.js', + name: 'default' + }" +`; + +exports[`covers cases shown in fixtures/no-client-export.js 1`] = `""`; + +exports[`covers cases shown in fixtures/no-client-export-no-export.js 1`] = `""`; diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-exports.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-exports.js new file mode 100644 index 0000000000000..0463b58d92c7c --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-exports.js @@ -0,0 +1,9 @@ +"client export" + +exports.a = { + b: 1 +} + +exports.c = { + d: 2 +} diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-module-exports.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-module-exports.js new file mode 100644 index 0000000000000..4030a5e766651 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/cjs-module-exports.js @@ -0,0 +1,8 @@ +"client export" + +// TODO: Handle, otherwise remove and document if we decide not to support or it's not supported by React's implementation + +// module.exports = { +// a: 1, +// b: 2 +// } \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-aggregation.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-aggregation.js new file mode 100644 index 0000000000000..f73488cfe5390 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-aggregation.js @@ -0,0 +1,9 @@ +"client export" + +// TODO: Handle, otherwise remove and document if we decide not to support or it's not supported by React's implementation + +// export * from "./some-module" +// export * as a from "some-module" +// export { b, c } from "some-module" +// export { d as e, f as g, h } from "some-module" +// export { default } from "some-module" \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-declaration.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-declaration.js new file mode 100644 index 0000000000000..2d4dc1efe937e --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-declaration.js @@ -0,0 +1,12 @@ +"client export" + +export let a, b +export var c, d +export const e = 1, f = 2 +export function functionName() {} +export class ClassName {} +export const { g, h: foo } = { g: "baz", h: 101 } +export const [i, j] = ["baz", 101] +export function withJSX() { + return
hello world
+} diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-anonymous.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-anonymous.js new file mode 100644 index 0000000000000..1f9145e9c615d --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-anonymous.js @@ -0,0 +1,3 @@ +"client export" + +export default class {} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-named.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-named.js new file mode 100644 index 0000000000000..46d7de704051a --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-class-named.js @@ -0,0 +1,3 @@ +"client export" + +export default class ClassName {} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-expression.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-expression.js new file mode 100644 index 0000000000000..ec6e0df52129b --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-expression.js @@ -0,0 +1,5 @@ +"client export" + +const a = 1 + +export default a \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-anonymous.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-anonymous.js new file mode 100644 index 0000000000000..e82f335229513 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-anonymous.js @@ -0,0 +1,3 @@ +"client export" + +export default function () {} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-named.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-named.js new file mode 100644 index 0000000000000..c3605df28e320 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-default-function-named.js @@ -0,0 +1,3 @@ +"client export" + +export default function functionName() {} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-list.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-list.js new file mode 100644 index 0000000000000..e197088b18baf --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/esm-list.js @@ -0,0 +1,7 @@ +"client export" + +const a = 1, b = 2, c = 3 + +export { a, b } +export { a as d, b as e } +export { c as default } \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export-no-export.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export-no-export.js new file mode 100644 index 0000000000000..61dfc29d9ebe7 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export-no-export.js @@ -0,0 +1,3 @@ +function noClientExport() { + return `No "client export" found in this file, and the function itself is not exported` +} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export.js b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export.js new file mode 100644 index 0000000000000..cdf6a5532909a --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/fixtures/no-client-export.js @@ -0,0 +1,3 @@ +export function noClientExport() { + return `No "client export" found in this file` +} \ No newline at end of file diff --git a/packages/gatsby/src/utils/webpack/loaders/__tests__/partial-hydration-reference-loader.ts b/packages/gatsby/src/utils/webpack/loaders/__tests__/partial-hydration-reference-loader.ts new file mode 100644 index 0000000000000..fd188cce2e755 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/__tests__/partial-hydration-reference-loader.ts @@ -0,0 +1,22 @@ +import fs from "fs-extra" +import path from "path" + +// @ts-ignore - Doesn't understand CJS default exports? +import partialHydrationReferenceLoader from "../partial-hydration-reference-loader" + +const rootContext = __dirname +const fixturesPath = path.resolve(__dirname, `./fixtures`) +const fixtures = fs.readdirSync(fixturesPath) + +for (const fixture of fixtures) { + const resourcePath = path.resolve(__dirname, `./fixtures/${fixture}`) + const source = fs.readFileSync(resourcePath).toString() + + it(`covers cases shown in fixtures/${fixture}`, async () => { + const mutatedSource = await partialHydrationReferenceLoader.call( + { resourcePath, rootContext }, + source + ) + expect(mutatedSource).toMatchSnapshot() + }) +} diff --git a/packages/gatsby/src/utils/webpack/loaders/partial-hydration-reference-loader.ts b/packages/gatsby/src/utils/webpack/loaders/partial-hydration-reference-loader.ts new file mode 100644 index 0000000000000..0e34026754467 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/loaders/partial-hydration-reference-loader.ts @@ -0,0 +1,157 @@ +/* eslint-disable @babel/no-invalid-this */ +import url from "url" +import { parse } from "acorn-loose" +import { simple as walk } from "acorn-walk" +import type { LoaderDefinitionFunction } from "webpack" +import type { Node } from "acorn-loose" +import type { + ExportNamedDeclaration, + ExportDefaultDeclaration, + AssignmentExpression, + Directive, +} from "estree" + +function createNamedReference(name: string, moduleId: string): string { + return `export const ${name} = { + $$typeof: Symbol.for('react.module.reference'), + filepath: '${moduleId}', + name: '${name}' + }` +} + +function createDefaultReference(name: string, moduleId: string): string { + return `export default { + $$typeof: Symbol.for('react.module.reference'), + filepath: '${moduleId}', + name: '${name}' + }` +} + +const partialHydrationReferenceLoader: LoaderDefinitionFunction< + Record +> = async function partialHydrationReferenceLoader(content) { + if (!content.includes(`client export`)) { + return content + } + + const references: Array = [] + let hasClientExportDirective = false + + const moduleId = url + .pathToFileURL(this.resourcePath) + .href.replace(this.rootContext.replace(/\\/g, `/`), ``) + .replace(/file:\/{3,4}/g, `file://`) + + walk(parse(content, { ecmaVersion: 2020, sourceType: `module` }), { + ExpressionStatement(plainAcornNode: Node) { + const node = plainAcornNode as unknown as Directive + + if (node.directive === `client export`) { + hasClientExportDirective = true + } + }, + ExportNamedDeclaration(plainAcornNode: Node) { + const node = plainAcornNode as unknown as ExportNamedDeclaration + + if (!hasClientExportDirective) return + + // Handle cases shown in `fixtures/esm-declaration.js` + switch (node?.declaration?.type) { + case `VariableDeclaration`: + for (const { id } of node.declaration.declarations || []) { + if (id.type === `Identifier` && id.name) { + references.push(createNamedReference(id.name, moduleId)) + } + + if (id.type === `ObjectPattern`) { + // @ts-ignore Wrong type + for (const { value } of id.properties) { + if (value.type === `Identifier` && value.name) { + references.push(createNamedReference(value.name, moduleId)) + } + } + } + + if (id.type === `ArrayPattern`) { + for (const element of id.elements || []) { + if (element?.type === `Identifier` && element.name) { + references.push(createNamedReference(element.name, moduleId)) + } + } + } + } + break + case `FunctionDeclaration`: + case `ClassDeclaration`: + if ( + node.declaration.id?.type === `Identifier` && + node.declaration.id.name + ) { + references.push( + createNamedReference(node.declaration.id.name, moduleId) + ) + } + break + } + + // Handle cases shown in `fixtures/esm-list.js` + if (node.specifiers.length) { + for (const specifier of node.specifiers) { + if ( + specifier.type === `ExportSpecifier` && + specifier.exported.type === `Identifier` && + specifier.exported.name + ) { + if (specifier.exported.name === `default`) { + references.push(createDefaultReference(`default`, moduleId)) + } else { + references.push( + createNamedReference(specifier.exported.name, moduleId) + ) + } + } + } + } + }, + ExportDefaultDeclaration(plainAcornNode: Node) { + const node = plainAcornNode as unknown as ExportDefaultDeclaration + + if (!hasClientExportDirective) return + + switch (node.declaration.type) { + // Handle cases shown in `fixtures/esm-default-expression.js` + case `Identifier`: + if (node.declaration.name) { + references.push(createDefaultReference(`default`, moduleId)) + } + break + case `FunctionDeclaration`: + case `ClassDeclaration`: + references.push(createDefaultReference(`default`, moduleId)) + break + } + }, + // TODO: Explore how to only walk top level tokens + AssignmentExpression(plainAcornNode) { + const node = plainAcornNode as unknown as AssignmentExpression + const { left } = node + + if (!hasClientExportDirective) return + + // Handle cases shown in `fixtures/cjs-exports.js` + if ( + left?.type === `MemberExpression` && + left?.object?.type === `Identifier` && + left.object?.name === `exports` && + left?.property?.type === `Identifier` && + left.property?.name + ) { + references.push(createNamedReference(left.property.name, moduleId)) + } + }, + }) + + return references.join(`\n`) +} + +module.exports = partialHydrationReferenceLoader diff --git a/packages/gatsby/src/utils/webpack/plugins/partial-hydration.ts b/packages/gatsby/src/utils/webpack/plugins/partial-hydration.ts new file mode 100644 index 0000000000000..3d5eac100cbb0 --- /dev/null +++ b/packages/gatsby/src/utils/webpack/plugins/partial-hydration.ts @@ -0,0 +1,311 @@ +import * as path from "path" +import Template from "webpack/lib/Template" +import ModuleDependency from "webpack/lib/dependencies/ModuleDependency" +import NullDependency from "webpack/lib/dependencies/NullDependency" +import url from "url" +import webpack, { Module, NormalModule, Dependency, javascript } from "webpack" + +interface IModuleExport { + id: string + chunks: Array + name: string +} + +interface IDirective { + directive?: string +} + +/** + * @see https://github.com/facebook/react/blob/3f70e68cea8d2ed0f53d35420105ae20e22ce428/packages/react-server-dom-webpack/src/ReactFlightWebpackPlugin.js#L27-L35 + */ +class ClientReferenceDependency extends ModuleDependency { + constructor(request) { + super(request) + } + + get type(): string { + return `client-reference` + } +} + +/** + * inspiration and code mostly comes from https://github.com/facebook/react/blob/3f70e68cea8d2ed0f53d35420105ae20e22ce428/packages/react-server-dom-webpack/src/ReactFlightWebpackPlugin.js + */ +export class PartialHydrationPlugin { + name = `PartialHydrationPlugin` + _manifestPath: string + _rootFilePath: string + _references: Array = [] + _clientModules = new Set() + + constructor(manifestPath: string, rootFilePath: string) { + this._manifestPath = manifestPath + this._rootFilePath = rootFilePath + } + + _generateClientReferenceChunk( + reference: NormalModule, + module: NormalModule, + rootContext: string + ): void { + const chunkName = Template.toPath( + // @ts-ignore - types are incorrect + path.relative(rootContext, reference.userRequest) + ) + + const dep = new ClientReferenceDependency(reference.rawRequest) + const block = new webpack.AsyncDependenciesBlock( + { + name: chunkName, + }, + undefined, + // @ts-ignore - types are incorrect + reference.request + ) + + block.addDependency(dep as Dependency) + module.addBlock(block) + } + + _generateManifest( + _chunkGroups: webpack.Compilation["chunkGroups"], + moduleGraph: webpack.Compilation["moduleGraph"], + chunkGraph: webpack.Compilation["chunkGraph"], + rootContext: string + ): Record> { + const json: Record> = {} + // @see https://github.com/facebook/react/blob/3f70e68cea8d2ed0f53d35420105ae20e22ce428/packages/react-server-dom-webpack/src/ReactFlightWebpackPlugin.js#L220-L252 + const recordModule = ( + id: string, + module: Module | NormalModule, + exports: Array<{ originalExport: string; resolvedExport: string }>, + chunkIds: Array + ): void => { + if ( + // @ts-ignore - types are incorrect + !module.resource + ) { + return + } + + const normalModule: NormalModule = module as NormalModule + + const moduleExports: Record = {} + exports.forEach(({ originalExport, resolvedExport }) => { + moduleExports[originalExport] = { + id: id, + chunks: chunkIds, + name: resolvedExport, + } + }) + + const href = url + .pathToFileURL(normalModule.resource) + .href.replace(rootContext.replace(/\\/g, `/`), ``) + .replace(/file:\/{3,4}/g, `file://`) + if (href !== undefined) { + json[href] = moduleExports + } + } + + const toRecord: Map< + webpack.Module, + Map< + webpack.Module, + Array<{ + originalExport: string + resolvedExport: string + }> + > + > = new Map() + for (const clientModule of this._clientModules) { + for (const connection of moduleGraph.getIncomingConnections( + clientModule + )) { + if (connection.dependency) { + if (toRecord.has(connection.module)) { + continue + } + + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + const childMap = new Map() + toRecord.set(connection.module, childMap) + + for (const exportInfo of moduleGraph.getExportsInfo(connection.module) + .exports) { + if (exportInfo.isReexport()) { + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + const targetInfo = exportInfo.getTarget(moduleGraph)! + if (!childMap.has(targetInfo.module)) { + childMap.set(targetInfo.module, []) + } + + childMap.get(targetInfo.module)?.push({ + originalExport: exportInfo.name, + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + resolvedExport: targetInfo.export![0], + }) + } else { + if (!childMap.has(connection.module)) { + childMap.set(connection.module, []) + } + + childMap.get(connection.module)?.push({ + originalExport: exportInfo.name, + resolvedExport: exportInfo.name, + }) + } + } + } + } + } + + for (const [originalModule, resolvedMap] of toRecord) { + for (const [resolvedModule, exports] of resolvedMap) { + const chunkIds: Set = new Set() + for (const chunk of chunkGraph.getModuleChunksIterable( + resolvedModule + )) { + for (const group of chunk.groupsIterable) { + for (const chunkInGroup of group.chunks) { + if (chunkInGroup.id) { + chunkIds.add(chunkInGroup.id as string) + } + } + } + } + + const moduleId = chunkGraph.getModuleId(resolvedModule) as string + recordModule(moduleId, originalModule, exports, Array.from(chunkIds)) + } + } + + toRecord.clear() + + return json + } + + apply(compiler: webpack.Compiler): void { + compiler.hooks.thisCompilation.tap( + this.name, + (compilation, { normalModuleFactory }) => { + // tell webpack that this is a regular javascript module + compilation.dependencyFactories.set( + ClientReferenceDependency as ModuleDependency, + normalModuleFactory + ) + // don't add extra code to the source file + compilation.dependencyTemplates.set( + ClientReferenceDependency as ModuleDependency, + new NullDependency.Template() + ) + + // const entryModule: webpack.NormalModule | null = null + const handler = (parser: javascript.JavascriptParser): void => { + parser.hooks.program.tap(this.name, ast => { + const hasClientExportDirective = ast.body.find( + statement => + statement.type === `ExpressionStatement` && + (statement as IDirective).directive === `client export` + ) + + const module = parser.state.module + + if (hasClientExportDirective) { + this._clientModules.add(module) + + // if (entryModule) { + // console.log(`parse`, module.resource) + // this._generateClientReferenceChunk( + // module, + // entryModule, + // compilation.options.context as string + // ) + // entryModule.invalidateBuild() + // } + } + + // if (module.resource.includes(`production-app`) && !entryModule) { + // entryModule = module + + // for (const clientModule of this._clientModules) { + // this._generateClientReferenceChunk( + // clientModule, + // entryModule, + // compilation.options.context as string + // ) + // } + // } + }) + } + + compilation.hooks.optimizeChunkModules.tap( + this.name, + // eslint-disable-next-line @typescript-eslint/no-unused-vars + () => { + // 1. move clientModules into their own chunk + // 2. disconnect module from original chunk + + for (const clientModule of this._clientModules) { + const chunkName = Template.toPath( + // @ts-ignore - types are incorrect + path.relative( + compilation.options.context as string, + clientModule.userRequest + ) + ) + + const selectedChunks = Array.from( + compilation.chunkGraph.getModuleChunksIterable(clientModule) + ) + const chunk = compilation.addChunk(chunkName) + chunk.chunkReason = `PartialHydration client module` + compilation.chunkGraph.connectChunkAndModule(chunk, clientModule) + + for (const connectedChunk of selectedChunks) { + compilation.chunkGraph.disconnectChunkAndModule( + connectedChunk, + clientModule + ) + connectedChunk.split(chunk) + } + } + } + ) + + normalModuleFactory.hooks.parser + .for(`javascript/auto`) + .tap(this.name, handler) + normalModuleFactory.hooks.parser + .for(`javascript/esm`) + .tap(this.name, handler) + normalModuleFactory.hooks.parser + .for(`javascript/dynamic`) + .tap(this.name, handler) + + compilation.hooks.processAssets.tap( + { + name: this.name, + stage: webpack.Compilation.PROCESS_ASSETS_STAGE_REPORT, + }, + () => { + const manifest = this._generateManifest( + compilation.chunkGroups, + compilation.moduleGraph, + compilation.chunkGraph, + compilation.options.context as string + ) + + compilation.emitAsset( + this._manifestPath, + new webpack.sources.RawSource( + JSON.stringify(manifest, null, 2), + false + ) + ) + } + ) + } + ) + } +} diff --git a/packages/gatsby/src/utils/worker/child/index.ts b/packages/gatsby/src/utils/worker/child/index.ts index fb57e259766f1..13ac08e1d8038 100644 --- a/packages/gatsby/src/utils/worker/child/index.ts +++ b/packages/gatsby/src/utils/worker/child/index.ts @@ -13,7 +13,11 @@ if (isWorker) { } // Note: this doesn't check for conflicts between module exports -export { renderHTMLProd, renderHTMLDev } from "./render-html" +export { + renderHTMLProd, + renderHTMLDev, + renderPartialHydrationProd, +} from "./render-html" export { setInferenceMetadata, buildSchema } from "./schema" export { setComponents, runQueries, saveQueriesDependencies } from "./queries" export { loadConfigAndPlugins } from "./load-config-and-plugins" diff --git a/packages/gatsby/src/utils/worker/child/render-html.ts b/packages/gatsby/src/utils/worker/child/render-html.ts index 8ff193e6bae5e..7ae77f9874d50 100644 --- a/packages/gatsby/src/utils/worker/child/render-html.ts +++ b/packages/gatsby/src/utils/worker/child/render-html.ts @@ -3,7 +3,8 @@ import fs from "fs-extra" import Bluebird from "bluebird" import * as path from "path" -import { generateHtmlPath } from "gatsby-core-utils" +import { generateHtmlPath } from "gatsby-core-utils/page-html" +import { generatePageDataPath } from "gatsby-core-utils/page-data" import { truncate } from "lodash" import { @@ -21,15 +22,29 @@ import { // we want to force posix-style joins, so Windows doesn't produce backslashes for urls const { join } = path.posix +type IUnsafeBuiltinUsage = Array | undefined + declare global { namespace NodeJS { // eslint-disable-next-line @typescript-eslint/naming-convention interface Global { - unsafeBuiltinUsage: Array | undefined + unsafeBuiltinUsage: IUnsafeBuiltinUsage } } } +// Best effort typing the shape of errors we might throw +interface IRenderHTMLError extends Error { + message: string + name: string + code?: string + stack?: string + context?: { + path?: string + unsafeBuiltinsUsageByPagePath?: Record + } +} + /** * Used to track if renderHTMLProd / renderHTMLDev are called within same "session" (from same renderHTMLQueue call). * As long as sessionId remains the same we can rely on memoized/cached resources for templates, css file content for inlining and static query results. @@ -175,8 +190,10 @@ export const renderHTMLProd = async ({ if (e.unsafeBuiltinsUsage && e.unsafeBuiltinsUsage.length > 0) { unsafeBuiltinsUsageByPagePath[pagePath] = e.unsafeBuiltinsUsage } - // add some context to error so we can display more helpful message - e.context = { + + const htmlRenderError: IRenderHTMLError = e + + htmlRenderError.context = { path: pagePath, unsafeBuiltinsUsageByPagePath, } @@ -189,7 +206,7 @@ export const renderHTMLProd = async ({ const html = `

Preview build error

There was an error when building the preview page for this page ("${pagePath}").

Error

-
${e.stack}
+
${htmlRenderError?.stack}

Page component id

${pageData.componentChunkName}

Page data

@@ -197,11 +214,11 @@ export const renderHTMLProd = async ({ await fs.outputFile(generateHtmlPath(publicDir, pagePath), html) previewErrors[pagePath] = { - e, - message: e.message, - code: e.code, - stack: e.stack, - name: e.name, + e: htmlRenderError, + name: htmlRenderError.name, + message: htmlRenderError.message, + code: htmlRenderError?.code, + stack: htmlRenderError?.stack, } } else { throw e @@ -261,3 +278,119 @@ export const renderHTMLDev = async ({ { concurrency: 2 } ) } + +export async function renderPartialHydrationProd({ + paths, + envVars, + sessionId, +}: { + paths: Array + envVars: Array<[string, string | undefined]> + sessionId: number +}): Promise { + const publicDir = join(process.cwd(), `public`) + + const unsafeBuiltinsUsageByPagePath = {} + + // Check if we need to do setup and cache clearing. Within same session we can reuse memoized data, + // but it's not safe to reuse them in different sessions. Check description of `lastSessionId` for more details + if (sessionId !== lastSessionId) { + clearCaches() + + // This is being executed in child process, so we need to set some vars + // for modules that aren't bundled by webpack. + envVars.forEach(([key, value]) => (process.env[key] = value)) + + webpackStats = await readWebpackStats(publicDir) + + lastSessionId = sessionId + + if (global.unsafeBuiltinUsage && global.unsafeBuiltinUsage.length > 0) { + unsafeBuiltinsUsageByPagePath[`__import_time__`] = + global.unsafeBuiltinUsage + } + } + + for (const pagePath of paths) { + const pageData = await readPageData(publicDir, pagePath) + const { staticQueryContext } = await getStaticQueryContext( + pageData.staticQueryHashes + ) + + const pageRenderer = path.join( + process.cwd(), + `.cache`, + `partial-hydration`, + `render-page` + ) + + const { + getPageChunk, + StaticQueryServerContext, + renderToPipeableStream, + React, + } = require(pageRenderer) + const chunk = await getPageChunk({ + componentChunkName: pageData.componentChunkName, + }) + const outputPath = generatePageDataPath( + path.join(process.cwd(), `public`), + pagePath + ).replace(`.json`, `-rsc.json`) + + const stream = fs.createWriteStream(outputPath) + + const { pipe } = renderToPipeableStream( + React.createElement( + StaticQueryServerContext.Provider, + { value: staticQueryContext }, + [ + React.createElement(chunk.default, { + data: pageData.result.data, + pageContext: pageData.result.pageContext, + location: { + pathname: pageData.path, + }, + }), + ] + ), + JSON.parse( + fs.readFileSync( + path.join( + process.cwd(), + `.cache`, + `partial-hydration`, + `manifest.json` + ), + `utf8` + ) + ), + { + // React spits out the error here and does not emit it, we want to emit it + // so we can reject with the error and handle it upstream + onError: error => { + const partialHydrationError: IRenderHTMLError = error + + partialHydrationError.context = { + path: pagePath, + unsafeBuiltinsUsageByPagePath, + } + + stream.emit(`error`, error) + }, + } + ) + + await new Promise((resolve, reject) => { + stream.on(`error`, (error: IRenderHTMLError) => { + reject(error) + }) + + stream.on(`close`, () => { + resolve() + }) + + pipe(stream) + }) + } +} diff --git a/yarn.lock b/yarn.lock index f690a01cb9772..bbbee807e4ec6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -181,10 +181,10 @@ dependencies: "@babel/highlight" "^7.18.6" -"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.15.0", "@babel/compat-data@^7.17.0", "@babel/compat-data@^7.18.8": - version "7.18.8" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.18.8.tgz#2483f565faca607b8535590e84e7de323f27764d" - integrity sha512-HSmX4WZPPK3FUxYp7g2T6EyO8j96HlZJlxmKPSh6KAcqwyDrfx7hKjXpAW/0FhFfTJsR0Yt4lAjLI2coMptIHQ== +"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.15.0", "@babel/compat-data@^7.17.0", "@babel/compat-data@^7.19.0": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.19.0.tgz#2a592fd89bacb1fcde68de31bee4f2f2dacb0e86" + integrity sha512-y5rqgTTPTmaF5e2nVhOxw+Ur9HDJLsWb6U/KpgUzRZEdPfE6VOubXBKLdbcUTijzRptednSBDQbYZBOSqJxpJw== "@babel/core@7.12.3": version "7.12.3" @@ -231,20 +231,20 @@ source-map "^0.5.0" "@babel/core@^7.1.0", "@babel/core@^7.12.10", "@babel/core@^7.13.16", "@babel/core@^7.14.0", "@babel/core@^7.14.5", "@babel/core@^7.15.5", "@babel/core@^7.18.0", "@babel/core@^7.18.2", "@babel/core@^7.7.2", "@babel/core@^7.7.5": - version "7.18.10" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.18.10.tgz#39ad504991d77f1f3da91be0b8b949a5bc466fb8" - integrity sha512-JQM6k6ENcBFKVtWvLavlvi/mPcpYZ3+R+2EySDEMSMbp7Mn4FexlbbJVrx2R7Ijhr01T8gyqrOaABWIOgxeUyw== + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.19.0.tgz#d2f5f4f2033c00de8096be3c9f45772563e150c3" + integrity sha512-reM4+U7B9ss148rh2n1Qs9ASS+w94irYXga7c2jaQv9RVzpS7Mv1a9rnYYwuDa45G+DkORt9g6An2k/V4d9LbQ== dependencies: "@ampproject/remapping" "^2.1.0" "@babel/code-frame" "^7.18.6" - "@babel/generator" "^7.18.10" - "@babel/helper-compilation-targets" "^7.18.9" - "@babel/helper-module-transforms" "^7.18.9" - "@babel/helpers" "^7.18.9" - "@babel/parser" "^7.18.10" + "@babel/generator" "^7.19.0" + "@babel/helper-compilation-targets" "^7.19.0" + "@babel/helper-module-transforms" "^7.19.0" + "@babel/helpers" "^7.19.0" + "@babel/parser" "^7.19.0" "@babel/template" "^7.18.10" - "@babel/traverse" "^7.18.10" - "@babel/types" "^7.18.10" + "@babel/traverse" "^7.19.0" + "@babel/types" "^7.19.0" convert-source-map "^1.7.0" debug "^4.1.0" gensync "^1.0.0-beta.2" @@ -276,12 +276,12 @@ jsesc "^2.5.1" source-map "^0.5.0" -"@babel/generator@^7.12.1", "@babel/generator@^7.12.11", "@babel/generator@^7.12.5", "@babel/generator@^7.14.0", "@babel/generator@^7.16.8", "@babel/generator@^7.18.10", "@babel/generator@^7.7.2": - version "7.18.10" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.18.10.tgz#794f328bfabdcbaf0ebf9bf91b5b57b61fa77a2a" - integrity sha512-0+sW7e3HjQbiHbj1NeU/vN8ornohYlacAfZIaXhdoGweQqgcNy69COVciYYqEXJ/v+9OBA7Frxm4CVAuNqKeNA== +"@babel/generator@^7.12.1", "@babel/generator@^7.12.11", "@babel/generator@^7.12.5", "@babel/generator@^7.14.0", "@babel/generator@^7.16.8", "@babel/generator@^7.19.0", "@babel/generator@^7.7.2": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.19.0.tgz#785596c06425e59334df2ccee63ab166b738419a" + integrity sha512-S1ahxf1gZ2dpoiFgA+ohK9DIpz50bJ0CWs7Zlzb54Z4sG8qmdIrGrVqmy1sAtTVRb+9CU6U8VqT9L0Zj7hxHVg== dependencies: - "@babel/types" "^7.18.10" + "@babel/types" "^7.19.0" "@jridgewell/gen-mapping" "^0.3.2" jsesc "^2.5.1" @@ -300,12 +300,12 @@ "@babel/helper-explode-assignable-expression" "^7.14.5" "@babel/types" "^7.14.5" -"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.15.4", "@babel/helper-compilation-targets@^7.16.7", "@babel/helper-compilation-targets@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.18.9.tgz#69e64f57b524cde3e5ff6cc5a9f4a387ee5563bf" - integrity sha512-tzLCyVmqUiFlcFoAPLA/gL9TeYrF61VLNtb+hvkuVaB5SUjW7jcfrglBIX1vUIoT7CLP3bBlIMeyEsIl2eFQNg== +"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.15.4", "@babel/helper-compilation-targets@^7.16.7", "@babel/helper-compilation-targets@^7.19.0": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.19.0.tgz#537ec8339d53e806ed422f1e06c8f17d55b96bb0" + integrity sha512-Ai5bNWXIvwDvWM7njqsG3feMlL9hCVQsPYXodsZyLwshYkZVJt59Gftau4VrE8S9IT9asd2uSP1hG6wCNw+sXA== dependencies: - "@babel/compat-data" "^7.18.8" + "@babel/compat-data" "^7.19.0" "@babel/helper-validator-option" "^7.18.6" browserslist "^4.20.2" semver "^6.3.0" @@ -364,13 +364,13 @@ dependencies: semver "^6.3.0" -"@babel/helper-function-name@^7.15.4", "@babel/helper-function-name@^7.16.7", "@babel/helper-function-name@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.18.9.tgz#940e6084a55dee867d33b4e487da2676365e86b0" - integrity sha512-fJgWlZt7nxGksJS9a0XdSaI4XvpExnNIgRP+rVefWh5U7BL8pPuir6SJUmFKRfjWQ51OtWSzwOxhaH/EBWWc0A== +"@babel/helper-function-name@^7.15.4", "@babel/helper-function-name@^7.16.7", "@babel/helper-function-name@^7.19.0": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.19.0.tgz#941574ed5390682e872e52d3f38ce9d1bef4648c" + integrity sha512-WAwHBINyrpqywkUH0nTnNgI5ina5TFn85HKS0pbPDfxFfhyR/aNQEn4hGi1P1JyT//I0t4OgXUlofzWILRvS5w== dependencies: - "@babel/template" "^7.18.6" - "@babel/types" "^7.18.9" + "@babel/template" "^7.18.10" + "@babel/types" "^7.19.0" "@babel/helper-hoist-variables@^7.15.4", "@babel/helper-hoist-variables@^7.18.6": version "7.18.6" @@ -393,19 +393,19 @@ dependencies: "@babel/types" "^7.18.6" -"@babel/helper-module-transforms@^7.12.1", "@babel/helper-module-transforms@^7.14.5", "@babel/helper-module-transforms@^7.15.4", "@babel/helper-module-transforms@^7.17.7", "@babel/helper-module-transforms@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.18.9.tgz#5a1079c005135ed627442df31a42887e80fcb712" - integrity sha512-KYNqY0ICwfv19b31XzvmI/mfcylOzbLtowkw+mfvGPAQ3kfCnMLYbED3YecL5tPd8nAYFQFAd6JHp2LxZk/J1g== +"@babel/helper-module-transforms@^7.12.1", "@babel/helper-module-transforms@^7.14.5", "@babel/helper-module-transforms@^7.15.4", "@babel/helper-module-transforms@^7.17.7", "@babel/helper-module-transforms@^7.19.0": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.19.0.tgz#309b230f04e22c58c6a2c0c0c7e50b216d350c30" + integrity sha512-3HBZ377Fe14RbLIA+ac3sY4PTgpxHVkFrESaWhoI5PuyXPBBX8+C34qblV9G89ZtycGJCmCI/Ut+VUDK4bltNQ== dependencies: "@babel/helper-environment-visitor" "^7.18.9" "@babel/helper-module-imports" "^7.18.6" "@babel/helper-simple-access" "^7.18.6" "@babel/helper-split-export-declaration" "^7.18.6" "@babel/helper-validator-identifier" "^7.18.6" - "@babel/template" "^7.18.6" - "@babel/traverse" "^7.18.9" - "@babel/types" "^7.18.9" + "@babel/template" "^7.18.10" + "@babel/traverse" "^7.19.0" + "@babel/types" "^7.19.0" "@babel/helper-optimise-call-expression@^7.16.7": version "7.16.7" @@ -510,14 +510,14 @@ "@babel/traverse" "^7.15.4" "@babel/types" "^7.15.4" -"@babel/helpers@^7.12.1", "@babel/helpers@^7.12.5", "@babel/helpers@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.18.9.tgz#4bef3b893f253a1eced04516824ede94dcfe7ff9" - integrity sha512-Jf5a+rbrLoR4eNdUmnFu8cN5eNJT6qdTdOg5IHIzq87WwyRw9PwguLFOWYgktN/60IP4fgDUawJvs7PjQIzELQ== +"@babel/helpers@^7.12.1", "@babel/helpers@^7.12.5", "@babel/helpers@^7.19.0": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.19.0.tgz#f30534657faf246ae96551d88dd31e9d1fa1fc18" + integrity sha512-DRBCKGwIEdqY3+rPJgG/dKfQy9+08rHIAJx8q2p+HSWP87s2HCrQmaAMMyMll2kIXKCW0cO1RdQskx15Xakftg== dependencies: - "@babel/template" "^7.18.6" - "@babel/traverse" "^7.18.9" - "@babel/types" "^7.18.9" + "@babel/template" "^7.18.10" + "@babel/traverse" "^7.19.0" + "@babel/types" "^7.19.0" "@babel/highlight@^7.10.4", "@babel/highlight@^7.18.6": version "7.18.6" @@ -545,10 +545,10 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.3.tgz#a305415ebe7a6c7023b40b5122a0662d928334cd" integrity sha512-kFsOS0IbsuhO5ojF8Hc8z/8vEIOkylVBrjiZUbLTE3XFe0Qi+uu6HjzQixkFaqr0ZPAMZcBVxEwmsnsLPZ2Xsw== -"@babel/parser@^7.1.0", "@babel/parser@^7.12.3", "@babel/parser@^7.12.7", "@babel/parser@^7.13.16", "@babel/parser@^7.14.0", "@babel/parser@^7.15.5", "@babel/parser@^7.16.8", "@babel/parser@^7.18.10", "@babel/parser@^7.18.11", "@babel/parser@^7.3.3", "@babel/parser@^7.7.2": - version "7.18.11" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.11.tgz#68bb07ab3d380affa9a3f96728df07969645d2d9" - integrity sha512-9JKn5vN+hDt0Hdqn1PiJ2guflwP+B6Ga8qbDuoF0PzzVhrzsKIJo8yGqVk6CmMHiMei9w1C1Bp9IMJSIK+HPIQ== +"@babel/parser@^7.1.0", "@babel/parser@^7.12.3", "@babel/parser@^7.12.7", "@babel/parser@^7.13.16", "@babel/parser@^7.14.0", "@babel/parser@^7.15.5", "@babel/parser@^7.16.8", "@babel/parser@^7.18.10", "@babel/parser@^7.19.0", "@babel/parser@^7.3.3", "@babel/parser@^7.7.2": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.19.0.tgz#497fcafb1d5b61376959c1c338745ef0577aa02c" + integrity sha512-74bEXKX2h+8rrfQUfsBfuZZHzsEs6Eql4pqy/T4Nn6Y9wNPggQOqD6z6pn5Bl8ZfysKouFZT/UXEH94ummEeQw== "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.15.4": version "7.15.4" @@ -1422,7 +1422,7 @@ dependencies: regenerator-runtime "^0.13.4" -"@babel/template@^7.10.4", "@babel/template@^7.12.7", "@babel/template@^7.15.4", "@babel/template@^7.16.7", "@babel/template@^7.18.10", "@babel/template@^7.18.6", "@babel/template@^7.3.3": +"@babel/template@^7.10.4", "@babel/template@^7.12.7", "@babel/template@^7.15.4", "@babel/template@^7.16.7", "@babel/template@^7.18.10", "@babel/template@^7.3.3": version "7.18.10" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.10.tgz#6f9134835970d1dbf0835c0d100c9f38de0c5e71" integrity sha512-TI+rCtooWHr3QJ27kJxfjutghu44DLnasDMwpDqCXVTal9RLp3RSYNh4NdBrRP2cQAoG9A8juOQl6P6oZG4JxA== @@ -1431,26 +1431,26 @@ "@babel/parser" "^7.18.10" "@babel/types" "^7.18.10" -"@babel/traverse@^7.1.0", "@babel/traverse@^7.1.6", "@babel/traverse@^7.12.1", "@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.14.0", "@babel/traverse@^7.15.4", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.18.10", "@babel/traverse@^7.18.9", "@babel/traverse@^7.7.2": - version "7.18.11" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.11.tgz#3d51f2afbd83ecf9912bcbb5c4d94e3d2ddaa16f" - integrity sha512-TG9PiM2R/cWCAy6BPJKeHzNbu4lPzOSZpeMfeNErskGpTJx6trEvFaVCbDvpcxwy49BKWmEPwiW8mrysNiDvIQ== +"@babel/traverse@^7.1.0", "@babel/traverse@^7.1.6", "@babel/traverse@^7.12.1", "@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.14.0", "@babel/traverse@^7.15.4", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.19.0", "@babel/traverse@^7.7.2": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.19.0.tgz#eb9c561c7360005c592cc645abafe0c3c4548eed" + integrity sha512-4pKpFRDh+utd2mbRC8JLnlsMUii3PMHjpL6a0SZ4NMZy7YFP9aXORxEhdMVOc9CpWtDF09IkciQLEhK7Ml7gRA== dependencies: "@babel/code-frame" "^7.18.6" - "@babel/generator" "^7.18.10" + "@babel/generator" "^7.19.0" "@babel/helper-environment-visitor" "^7.18.9" - "@babel/helper-function-name" "^7.18.9" + "@babel/helper-function-name" "^7.19.0" "@babel/helper-hoist-variables" "^7.18.6" "@babel/helper-split-export-declaration" "^7.18.6" - "@babel/parser" "^7.18.11" - "@babel/types" "^7.18.10" + "@babel/parser" "^7.19.0" + "@babel/types" "^7.19.0" debug "^4.1.0" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.0.0-beta.49", "@babel/types@^7.12.1", "@babel/types@^7.12.7", "@babel/types@^7.14.5", "@babel/types@^7.15.4", "@babel/types@^7.16.0", "@babel/types@^7.16.7", "@babel/types@^7.16.8", "@babel/types@^7.17.0", "@babel/types@^7.18.10", "@babel/types@^7.18.6", "@babel/types@^7.18.9", "@babel/types@^7.2.0", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": - version "7.18.10" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.10.tgz#4908e81b6b339ca7c6b7a555a5fc29446f26dde6" - integrity sha512-MJvnbEiiNkpjo+LknnmRrqbY1GPUUggjv+wQVjetM/AONoupqRALB7I6jGqNUAZsKcRIEu2J6FRFvsczljjsaQ== +"@babel/types@^7.0.0", "@babel/types@^7.0.0-beta.49", "@babel/types@^7.12.1", "@babel/types@^7.12.7", "@babel/types@^7.14.5", "@babel/types@^7.15.4", "@babel/types@^7.16.0", "@babel/types@^7.16.7", "@babel/types@^7.16.8", "@babel/types@^7.17.0", "@babel/types@^7.18.10", "@babel/types@^7.18.6", "@babel/types@^7.19.0", "@babel/types@^7.2.0", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4": + version "7.19.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.19.0.tgz#75f21d73d73dc0351f3368d28db73465f4814600" + integrity sha512-YuGopBq3ke25BVSiS6fgF49Ul9gH1x70Bcr6bqRLjWCkcX8Hre1/5+z+IiWOIerRMSSEfGZVB9z9kyq7wVs9YA== dependencies: "@babel/helper-string-parser" "^7.18.10" "@babel/helper-validator-identifier" "^7.18.6" @@ -3016,15 +3016,15 @@ "@lukeed/csprng" "^1.0.0" "@mdx-js/mdx@^2.1.1": - version "2.1.1" - resolved "https://registry.npmjs.org/@mdx-js/mdx/-/mdx-2.1.1.tgz#6d8b9b75456d7685a52c3812b1c3e4830c7458fb" - integrity sha512-SXC18cChut3F2zkVXwsb2no0fzTQ1z6swjK13XwFbF5QU/SFQM0orAItPypSdL3GvqYyzVJtz8UofzJhPEQtMw== + version "2.1.3" + resolved "https://registry.yarnpkg.com/@mdx-js/mdx/-/mdx-2.1.3.tgz#d5821920ebe546b45192f4c7a64dcc68a658f7f9" + integrity sha512-ahbb47HJIJ4xnifaL06tDJiSyLEy1EhFAStO7RZIm3GTa7yGW3NGhZaj+GUCveFgl5oI54pY4BgiLmYm97y+zg== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" "@types/mdx" "^2.0.0" - astring "^1.6.0" estree-util-build-jsx "^2.0.0" estree-util-is-identifier-name "^2.0.0" + estree-util-to-js "^1.1.0" estree-walker "^3.0.0" hast-util-to-estree "^2.0.0" markdown-extensions "^1.0.0" @@ -3840,7 +3840,7 @@ "@types/acorn@^4.0.0": version "4.0.6" - resolved "https://registry.npmjs.org/@types/acorn/-/acorn-4.0.6.tgz#d61ca5480300ac41a7d973dd5b84d0a591154a22" + resolved "https://registry.yarnpkg.com/@types/acorn/-/acorn-4.0.6.tgz#d61ca5480300ac41a7d973dd5b84d0a591154a22" integrity sha512-veQTnWP+1D/xbxVrPC3zHnCZRjSrKfhbMUlEA43iMZLu7EsnTtkJklIuwrCPbOi8YkvDQAiW05VQQFvvz9oieQ== dependencies: "@types/estree" "*" @@ -4031,7 +4031,7 @@ "@types/debug@^4.0.0": version "4.1.7" - resolved "https://registry.npmjs.org/@types/debug/-/debug-4.1.7.tgz#7cc0ea761509124709b8b2d1090d8f6c17aadb82" + resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.7.tgz#7cc0ea761509124709b8b2d1090d8f6c17aadb82" integrity sha512-9AonUzyTjXXhEOa0DnqpzZi6VHlqKMswga9EXjpXnnqxwLtdvPPtlO8evrI5D9S6asFRCQ6v+wpiUKbw+vKqyg== dependencies: "@types/ms" "*" @@ -4060,32 +4060,32 @@ "@types/estree" "*" "@types/json-schema" "*" -"@types/estree-jsx@^0.0.1": - version "0.0.1" - resolved "https://registry.npmjs.org/@types/estree-jsx/-/estree-jsx-0.0.1.tgz#c36d7a1afeb47a95a8ee0b7bc8bc705db38f919d" - integrity sha512-gcLAYiMfQklDCPjQegGn0TBAn9it05ISEsEhlKQUddIk7o2XDokOcTN7HBO8tznM0D9dGezvHEfRZBfZf6me0A== +"@types/estree-jsx@^1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@types/estree-jsx/-/estree-jsx-1.0.0.tgz#7bfc979ab9f692b492017df42520f7f765e98df1" + integrity sha512-3qvGd0z8F2ENTGr/GG1yViqfiKmRfrXVx5sJyHGFu3z7m5g5utCQtGp/g29JnjflhtQJBv1WDQukHiT58xPcYQ== dependencies: "@types/estree" "*" -"@types/estree@*", "@types/estree@^0.0.51": - version "0.0.51" - resolved "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz#cfd70924a25a3fd32b218e5e420e6897e1ac4f40" - integrity sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ== +"@types/estree@*", "@types/estree@^1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.0.tgz#5fb2e536c1ae9bf35366eed879e827fa59ca41c2" + integrity sha512-WulqXMDUTYAXCjZnk6JtIHPigp55cVtDgDrO2gHRwhyJto21+1zbVCtOYB2L1F9w4qCQ0rOGWBnBe0FNTiEJIQ== "@types/estree@0.0.39": version "0.0.39" resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f" -"@types/estree@^0.0.46": - version "0.0.46" - resolved "https://registry.npmjs.org/@types/estree/-/estree-0.0.46.tgz#0fb6bfbbeabd7a30880504993369c4bf1deab1fe" - integrity sha512-laIjwTQaD+5DukBZaygQ79K1Z0jb1bPEMRrkXSLjtCcZm+abyp5YbrqpSLzD42FwWW6gK/aS4NYpJ804nG2brg== - "@types/estree@^0.0.50": version "0.0.50" resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.50.tgz#1e0caa9364d3fccd2931c3ed96fdbeaa5d4cca83" integrity sha512-C6N5s2ZFtuZRj54k2/zyRhNDjJwwcViAM3Nbm8zjBpbqAdZ00mr0CFxvSKeO8Y/e03WVFLpQMdHYVfUd6SB+Hw== +"@types/estree@^0.0.51": + version "0.0.51" + resolved "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz#cfd70924a25a3fd32b218e5e420e6897e1ac4f40" + integrity sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ== + "@types/events@*": version "1.2.0" resolved "https://registry.yarnpkg.com/@types/events/-/events-1.2.0.tgz#81a6731ce4df43619e5c8c945383b3e62a89ea86" @@ -4282,13 +4282,13 @@ "@types/mdurl@^1.0.0": version "1.0.2" - resolved "https://registry.npmjs.org/@types/mdurl/-/mdurl-1.0.2.tgz#e2ce9d83a613bacf284c7be7d491945e39e1f8e9" + resolved "https://registry.yarnpkg.com/@types/mdurl/-/mdurl-1.0.2.tgz#e2ce9d83a613bacf284c7be7d491945e39e1f8e9" integrity sha512-eC4U9MlIcu2q0KQmXszyn5Akca/0jrQmwDRgpAMJai7qBWq4amIQhZyNau4VYGtCeALvW1/NtjzJJ567aZxfKA== "@types/mdx@^2.0.0": - version "2.0.1" - resolved "https://registry.npmjs.org/@types/mdx/-/mdx-2.0.1.tgz#e4c05d355d092d7b58db1abfe460e53f41102ac8" - integrity sha512-JPEv4iAl0I+o7g8yVWDwk30es8mfVrjkvh5UeVR2sYPpZCK44vrAPsbJpIS+rJAUxLgaSAMKTEH5Vn5qd9XsrQ== + version "2.0.2" + resolved "https://registry.yarnpkg.com/@types/mdx/-/mdx-2.0.2.tgz#64be19baddba4323ae7893e077e98759316fe279" + integrity sha512-mJGfgj4aWpiKb8C0nnJJchs1sHBHn0HugkVfqqyQi7Wn6mBRksLeQsPOFvih/Pu8L1vlDzfe/LidhVHBeUk3aQ== "@types/micromatch@^4.0.1", "@types/micromatch@^4.0.2": version "4.0.2" @@ -4320,7 +4320,7 @@ "@types/ms@*": version "0.7.31" - resolved "https://registry.npmjs.org/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" + resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA== "@types/node-fetch@2", "@types/node-fetch@^2.5.10", "@types/node-fetch@^2.5.12": @@ -5034,6 +5034,13 @@ acorn-jsx@^5.0.0, acorn-jsx@^5.0.1, acorn-jsx@^5.3.1, acorn-jsx@^5.3.2: resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== +acorn-loose@^8.3.0: + version "8.3.0" + resolved "https://registry.yarnpkg.com/acorn-loose/-/acorn-loose-8.3.0.tgz#0cd62461d21dce4f069785f8d3de136d5525029a" + integrity sha512-75lAs9H19ldmW+fAbyqHdjgdCrz0pWGXKmnqFoh8PyVd1L2RIb4RzYrSjmopeqv3E1G3/Pimu6GgLlrGbrkF7w== + dependencies: + acorn "^8.5.0" + acorn-node@^1.6.1: version "1.8.2" resolved "https://registry.yarnpkg.com/acorn-node/-/acorn-node-1.8.2.tgz#114c95d64539e53dede23de8b9d96df7c7ae2af8" @@ -5052,22 +5059,27 @@ acorn-walk@^7.0.0, acorn-walk@^7.1.1: resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-7.2.0.tgz#0de889a601203909b0fbe07b8938dc21d2e967bc" integrity sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA== +acorn-walk@^8.2.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.2.0.tgz#741210f2e2426454508853a2f44d0ab83b7f69c1" + integrity sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA== + acorn@^5.0.0: version "5.7.4" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== -acorn@^6.0.1: - version "6.4.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.1.tgz#531e58ba3f51b9dacb9a6646ca4debf5b14ca474" - integrity sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA== +acorn@^6.0.1, acorn@^6.2.1: + version "6.4.2" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.2.tgz#35866fd710528e92de10cf06016498e47e39e1e6" + integrity sha512-XtGIhXwF8YM8bJhGxG5kXgjkEuNGLTkoYqVE+KMR+aspr4KGYmKYg7yUe3KghyQ9yheNwLnjmzh/7+gfDBmHCQ== acorn@^7.0.0, acorn@^7.1.0, acorn@^7.1.1, acorn@^7.4.0, acorn@^7.4.1: version "7.4.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== -acorn@^8.0.0, acorn@^8.0.4, acorn@^8.2.4, acorn@^8.7.1: +acorn@^8.0.0, acorn@^8.0.4, acorn@^8.2.4, acorn@^8.5.0, acorn@^8.7.1: version "8.8.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.0.tgz#88c0187620435c7f6015803f5539dae05a9dbea8" integrity sha512-QOxyigPVrpZ2GXT+PFyZTl6TtOFc5egxHIP9IlQ+RbupQuX4RkT/Bee4/kQuC02Xkzg84JcT7oLYtDIQxp+v7w== @@ -5624,9 +5636,9 @@ astral-regex@^2.0.0: resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-2.0.0.tgz#483143c567aeed4785759c0865786dc77d7d2e31" integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== -astring@^1.6.0, astring@^1.8.3: +astring@^1.8.0, astring@^1.8.3: version "1.8.3" - resolved "https://registry.npmjs.org/astring/-/astring-1.8.3.tgz#1a0ae738c7cc558f8e5ddc8e3120636f5cebcb85" + resolved "https://registry.yarnpkg.com/astring/-/astring-1.8.3.tgz#1a0ae738c7cc558f8e5ddc8e3120636f5cebcb85" integrity sha512-sRpyiNrx2dEYIMmUXprS8nlpRg2Drs8m9ElX9vVEXaCB4XEAJhKfs7IcX0IwShjuOAjLR6wzIrgoptz1n19i1A== async-cache@^1.1.0: @@ -6083,7 +6095,7 @@ bail@^1.0.0: bail@^2.0.0: version "2.0.2" - resolved "https://registry.npmjs.org/bail/-/bail-2.0.2.tgz#d26f5cd8fe5d6f832a31517b9f7c356040ba6d5d" + resolved "https://registry.yarnpkg.com/bail/-/bail-2.0.2.tgz#d26f5cd8fe5d6f832a31517b9f7c356040ba6d5d" integrity sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw== balanced-match@^1.0.0: @@ -6745,7 +6757,7 @@ ccount@^1.0.0: ccount@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/ccount/-/ccount-2.0.1.tgz#17a3bf82302e0870d6da43a01311a8bc02a3ecf5" + resolved "https://registry.yarnpkg.com/ccount/-/ccount-2.0.1.tgz#17a3bf82302e0870d6da43a01311a8bc02a3ecf5" integrity sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg== cfb@~1.2.1: @@ -6869,7 +6881,7 @@ character-entities-html4@^1.0.0: character-entities-html4@^2.0.0: version "2.1.0" - resolved "https://registry.npmjs.org/character-entities-html4/-/character-entities-html4-2.1.0.tgz#1f1adb940c971a4b22ba39ddca6b618dc6e56b2b" + resolved "https://registry.yarnpkg.com/character-entities-html4/-/character-entities-html4-2.1.0.tgz#1f1adb940c971a4b22ba39ddca6b618dc6e56b2b" integrity sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA== character-entities-legacy@^1.0.0: @@ -6878,7 +6890,7 @@ character-entities-legacy@^1.0.0: character-entities-legacy@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/character-entities-legacy/-/character-entities-legacy-3.0.0.tgz#76bc83a90738901d7bc223a9e93759fdd560125b" + resolved "https://registry.yarnpkg.com/character-entities-legacy/-/character-entities-legacy-3.0.0.tgz#76bc83a90738901d7bc223a9e93759fdd560125b" integrity sha512-RpPp0asT/6ufRm//AJVwpViZbGM/MkjQFxJccQRHmISF/22NBtsHqAWmL+/pmkPWoIUJdWyeVleTl1wydHATVQ== character-entities@^1.0.0: @@ -6886,9 +6898,9 @@ character-entities@^1.0.0: resolved "https://registry.yarnpkg.com/character-entities/-/character-entities-1.2.2.tgz#58c8f371c0774ef0ba9b2aca5f00d8f100e6e363" character-entities@^2.0.0: - version "2.0.1" - resolved "https://registry.npmjs.org/character-entities/-/character-entities-2.0.1.tgz#98724833e1e27990dee0bd0f2b8a859c3476aac7" - integrity sha512-OzmutCf2Kmc+6DrFrrPS8/tDh2+DpnrfzdICHWhcVC9eOd0N1PXmQEE1a8iM4IziIAG+8tmTq3K+oo0ubH6RRQ== + version "2.0.2" + resolved "https://registry.yarnpkg.com/character-entities/-/character-entities-2.0.2.tgz#2d09c2e72cd9523076ccb21157dff66ad43fcc22" + integrity sha512-shx7oQ0Awen/BRIdkjkvz54PnEEI/EjwXDSIZp86/KKdbafHh1Df/RYGBhn4hbe2+uKC9FnT5UCEdyPz3ai9hQ== character-reference-invalid@^1.0.0: version "1.1.2" @@ -6896,7 +6908,7 @@ character-reference-invalid@^1.0.0: character-reference-invalid@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/character-reference-invalid/-/character-reference-invalid-2.0.1.tgz#85c66b041e43b47210faf401278abf808ac45cb9" + resolved "https://registry.yarnpkg.com/character-reference-invalid/-/character-reference-invalid-2.0.1.tgz#85c66b041e43b47210faf401278abf808ac45cb9" integrity sha512-iBZ4F4wRbyORVsu0jPV7gXkOsGYjGHPmAyv+HiHG8gi5PtC9KI2j1+v8/tlibRvjoWX027ypmG/n0HtO5t7unw== chardet@^0.4.0: @@ -7330,7 +7342,7 @@ comma-separated-tokens@^1.0.0, comma-separated-tokens@^1.0.1: comma-separated-tokens@^2.0.0: version "2.0.2" - resolved "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-2.0.2.tgz#d4c25abb679b7751c880be623c1179780fe1dd98" + resolved "https://registry.yarnpkg.com/comma-separated-tokens/-/comma-separated-tokens-2.0.2.tgz#d4c25abb679b7751c880be623c1179780fe1dd98" integrity sha512-G5yTt3KQN4Yn7Yk4ed73hlZ1evrFKXeUW3086p3PRFNp7m2vIjI6Pg+Kgb+oyzhd9F2qdcoj67+y3SdxL5XWsg== command-exists@^1.2.4: @@ -8635,9 +8647,9 @@ decimal.js@^10.2.1: integrity sha512-V0pfhfr8suzyPGOx3nmq4aHqabehUZn6Ch9kyFpV79TGDTWFmHqUqXdabR7QHqxzrYolF4+tVmJhUG4OURg5dQ== decode-named-character-reference@^1.0.0: - version "1.0.1" - resolved "https://registry.npmjs.org/decode-named-character-reference/-/decode-named-character-reference-1.0.1.tgz#57b2bd9112659cacbc449d3577d7dadb8e1f3d1b" - integrity sha512-YV/0HQHreRwKb7uBopyIkLG17jG6Sv2qUchk9qSoVJ2f+flwRsPNBO0hAnjt6mTNYUT+vw9Gy2ihXg4sUWPi2w== + version "1.0.2" + resolved "https://registry.yarnpkg.com/decode-named-character-reference/-/decode-named-character-reference-1.0.2.tgz#daabac9690874c394c81e4162a0304b35d824f0e" + integrity sha512-O8x12RzrUF8xyVcY0KJowWsmaJxQbmy0/EtnNtHRpsOcT7dFk5W598coHqBVpmWo1oQQfsCqfCmkZN5DJrZVdg== dependencies: character-entities "^2.0.0" @@ -8877,9 +8889,9 @@ deprecation@^2.0.0, deprecation@^2.3.1: integrity sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ== dequal@^2.0.0: - version "2.0.2" - resolved "https://registry.npmjs.org/dequal/-/dequal-2.0.2.tgz#85ca22025e3a87e65ef75a7a437b35284a7e319d" - integrity sha512-q9K8BlJVxK7hQYqa6XISGmBZbtQQWVXSrRrWreHC94rMt1QL/Impruc+7p2CYSYuVIUr+YCt6hjrs1kkdJRTug== + version "2.0.3" + resolved "https://registry.yarnpkg.com/dequal/-/dequal-2.0.3.tgz#2644214f1997d39ed0ee0ece72335490a7ac67be" + integrity sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA== destroy@1.2.0: version "1.2.0" @@ -10042,32 +10054,41 @@ estree-to-babel@^3.1.0: c8 "^7.6.0" estree-util-attach-comments@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/estree-util-attach-comments/-/estree-util-attach-comments-2.0.0.tgz#2c06d484dfcf841b5946bcb84d5412cbcd544e22" - integrity sha512-kT9YVRvlt2ewPp9BazfIIgXMGsXOEpOm57bK8aa4F3eOEndMml2JAETjWaG3SZYHmC6axSNIzHGY718dYwIuVg== + version "2.1.0" + resolved "https://registry.yarnpkg.com/estree-util-attach-comments/-/estree-util-attach-comments-2.1.0.tgz#47d69900588bcbc6bf58c3798803ec5f1f3008de" + integrity sha512-rJz6I4L0GaXYtHpoMScgDIwM0/Vwbu5shbMeER596rB2D1EWF6+Gj0e0UKzJPZrpoOc87+Q2kgVFHfjAymIqmw== dependencies: - "@types/estree" "^0.0.46" + "@types/estree" "^1.0.0" estree-util-build-jsx@^2.0.0, estree-util-build-jsx@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/estree-util-build-jsx/-/estree-util-build-jsx-2.1.0.tgz#629aa81fbb1b16ed628c7a9334d37bc8a2a3726f" - integrity sha512-gsBGfsY6LOJUIDwmMkTOcgCX+3r/LUjRBccgHMSW55PHjhZsV13RmPl/iwpAvW8KcQqoN9P0FEFWTSS2Zc5bGA== + version "2.2.0" + resolved "https://registry.yarnpkg.com/estree-util-build-jsx/-/estree-util-build-jsx-2.2.0.tgz#d4307bbeee28c14eb4d63b75c9aad28fa61d84f5" + integrity sha512-apsfRxF9uLrqosApvHVtYZjISPvTJ+lBiIydpC+9wE6cF6ssbhnjyQLqaIjgzGxvC2Hbmec1M7g91PoBayYoQQ== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" estree-util-is-identifier-name "^2.0.0" estree-walker "^3.0.0" estree-util-is-identifier-name@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/estree-util-is-identifier-name/-/estree-util-is-identifier-name-2.0.0.tgz#e2d3d2ae3032c017b2112832bfc5d8ba938c8010" - integrity sha512-aXXZFVMnBBDRP81vS4YtAYJ0hUkgEsXea7lNKWCOeaAquGb1Jm2rcONPB5fpzwgbNxulTvrWuKnp9UElUGAKeQ== + version "2.0.1" + resolved "https://registry.yarnpkg.com/estree-util-is-identifier-name/-/estree-util-is-identifier-name-2.0.1.tgz#cf07867f42705892718d9d89eb2d85eaa8f0fcb5" + integrity sha512-rxZj1GkQhY4x1j/CSnybK9cGuMFQYFPLq0iNyopqf14aOVLFtMv7Esika+ObJWPWiOHuMOAHz3YkWoLYYRnzWQ== -estree-util-visit@^1.0.0: +estree-util-to-js@^1.1.0: version "1.1.0" - resolved "https://registry.npmjs.org/estree-util-visit/-/estree-util-visit-1.1.0.tgz#c0ea7942c40ac7889a77b57a11e92f987744bc6f" - integrity sha512-3lXJ4Us9j8TUif9cWcQy81t9p5OLasnDuuhrFiqb+XstmKC1d1LmrQWYsY49/9URcfHE64mPypDBaNK9NwWDPQ== + resolved "https://registry.yarnpkg.com/estree-util-to-js/-/estree-util-to-js-1.1.0.tgz#3bd9bb86354063537cc3d81259be2f0d4c3af39f" + integrity sha512-490lbfCcpLk+ofK6HCgqDfYs4KAfq6QVvDw3+Bm1YoKRgiOjKiKYGAVQE1uwh7zVxBgWhqp4FDtp5SqunpUk1A== + dependencies: + "@types/estree-jsx" "^1.0.0" + astring "^1.8.0" + source-map "^0.7.0" + +estree-util-visit@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/estree-util-visit/-/estree-util-visit-1.2.0.tgz#aa0311a9c2f2aa56e9ae5e8b9d87eac14e4ec8f8" + integrity sha512-wdsoqhWueuJKsh5hqLw3j8lwFqNStm92VcwtAOAny8g/KS/l5Y8RISjR4k5W6skCj3Nirag/WUCMS0Nfy3sgsg== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" "@types/unist" "^2.0.0" estree-walker@^0.6.1: @@ -10087,7 +10108,7 @@ estree-walker@^2.0.1: estree-walker@^3.0.0: version "3.0.1" - resolved "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.1.tgz#c2a9fb4a30232f5039b7c030b37ead691932debd" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-3.0.1.tgz#c2a9fb4a30232f5039b7c030b37ead691932debd" integrity sha512-woY0RUD87WzMBUiZLx8NsYr23N5BKsOMZHhu2hoNRVh6NXGfoiT1KOL8G3UHlJAnEDGmfa5ubNA/AacfG+Kb0g== esutils@^2.0.2: @@ -11777,9 +11798,9 @@ graphql@^15.7.2, graphql@^15.8.0: integrity sha512-5gghUc24tP9HRznNpV2+FIoq3xKkj5dTQqf4v0CpdPbFVwFkWoxOM+o+2OC9ZSvjEMTjfmG9QT+gcvggTwW1zw== graphql@^16.3.0: - version "16.3.0" - resolved "https://registry.yarnpkg.com/graphql/-/graphql-16.3.0.tgz#a91e24d10babf9e60c706919bb182b53ccdffc05" - integrity sha512-xm+ANmA16BzCT5pLjuXySbQVFwH3oJctUVdy81w1sV0vBU0KgDdBGtxQOUd5zqOBk/JayAFeG8Dlmeq74rjm/A== + version "16.6.0" + resolved "https://registry.yarnpkg.com/graphql/-/graphql-16.6.0.tgz#c2dcffa4649db149f6282af726c8c83f1c7c5fdb" + integrity sha512-KPIBPDlW7NxrbT/eh4qPXz5FiFdL5UbaA0XUNz2Rp3Z3hqBSkbj0GVjwFDztsWVauZUWsbKHgMg++sk8UX0bkw== gray-matter@^2.1.0: version "2.1.1" @@ -12079,11 +12100,12 @@ hast-util-select@^5.0.0: zwitch "^2.0.0" hast-util-to-estree@^2.0.0: - version "2.0.2" - resolved "https://registry.npmjs.org/hast-util-to-estree/-/hast-util-to-estree-2.0.2.tgz#79c5bf588915610b3f0d47ca83a74dc0269c7dc2" - integrity sha512-UQrZVeBj6A9od0lpFvqHKNSH9zvDrNoyWKbveu1a2oSCXEDUI+3bnd6BoiQLPnLrcXXn/jzJ6y9hmJTTlvf8lQ== + version "2.1.0" + resolved "https://registry.yarnpkg.com/hast-util-to-estree/-/hast-util-to-estree-2.1.0.tgz#aeac70aad0102ae309570907b3f56a08231d5323" + integrity sha512-Vwch1etMRmm89xGgz+voWXvVHba2iiMdGMKmaMfYt35rbVtFDq8JNwwAIvi8zHMkO6Gvqo9oTMwJTmzVRfXh4g== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree" "^1.0.0" + "@types/estree-jsx" "^1.0.0" "@types/hast" "^2.0.0" "@types/unist" "^2.0.0" comma-separated-tokens "^2.0.0" @@ -12170,7 +12192,7 @@ hast-util-whitespace@^1.0.0: hast-util-whitespace@^2.0.0: version "2.0.0" - resolved "https://registry.npmjs.org/hast-util-whitespace/-/hast-util-whitespace-2.0.0.tgz#4fc1086467cc1ef5ba20673cb6b03cec3a970f1c" + resolved "https://registry.yarnpkg.com/hast-util-whitespace/-/hast-util-whitespace-2.0.0.tgz#4fc1086467cc1ef5ba20673cb6b03cec3a970f1c" integrity sha512-Pkw+xBHuV6xFeJprJe2BBEoDV+AvQySaz3pPDRUs5PNZEMQjpXJJueqrpcHIXxnWTcAGi/UOCgVShlkY6kLoqg== hastscript@^5.0.0: @@ -13005,7 +13027,7 @@ is-alphabetical@1.0.4, is-alphabetical@^1.0.0: is-alphabetical@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-2.0.1.tgz#01072053ea7c1036df3c7d19a6daaec7f19e789b" + resolved "https://registry.yarnpkg.com/is-alphabetical/-/is-alphabetical-2.0.1.tgz#01072053ea7c1036df3c7d19a6daaec7f19e789b" integrity sha512-FWyyY60MeTNyeSRpkM2Iry0G9hpr7/9kD40mD/cGQEuilcZYS4okz8SN2Q6rLCJ8gbCt6fN+rC+6tMGS99LaxQ== is-alphanumeric@^1.0.0: @@ -13021,7 +13043,7 @@ is-alphanumerical@^1.0.0: is-alphanumerical@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-2.0.1.tgz#7c03fbe96e3e931113e57f964b0a368cc2dfd875" + resolved "https://registry.yarnpkg.com/is-alphanumerical/-/is-alphanumerical-2.0.1.tgz#7c03fbe96e3e931113e57f964b0a368cc2dfd875" integrity sha512-hmbYhX/9MUMF5uh7tOXyK/n0ZvWpad5caBA17GsC6vyuCqaWliRG5K1qS9inmUhEMaOBIW7/whAnSwveW/LtZw== dependencies: is-alphabetical "^2.0.0" @@ -13125,7 +13147,7 @@ is-decimal@^1.0.0, is-decimal@^1.0.2: is-decimal@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/is-decimal/-/is-decimal-2.0.1.tgz#9469d2dc190d0214fd87d78b78caecc0cc14eef7" + resolved "https://registry.yarnpkg.com/is-decimal/-/is-decimal-2.0.1.tgz#9469d2dc190d0214fd87d78b78caecc0cc14eef7" integrity sha512-AAB9hiomQs5DXWcRB1rqsxGUstbRroFOPPVAomNk/3XHR5JyEZChOyTWe2oayKnsSsr/kcGqF+z6yuH6HHpN0A== is-descriptor@^0.1.0: @@ -13226,7 +13248,7 @@ is-hexadecimal@^1.0.0: is-hexadecimal@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/is-hexadecimal/-/is-hexadecimal-2.0.1.tgz#86b5bf668fca307498d319dfc03289d781a90027" + resolved "https://registry.yarnpkg.com/is-hexadecimal/-/is-hexadecimal-2.0.1.tgz#86b5bf668fca307498d319dfc03289d781a90027" integrity sha512-DgZQp241c8oO6cA1SbTEWiXeoxV42vlcJxgH+B3hi1AiqqKruZR3ZGF8In3fj4+/y/7rHvlOZLZtgJ/4ttYGZg== is-installed-globally@^0.1.0: @@ -13398,9 +13420,9 @@ is-plain-obj@^2.0.0: integrity sha512-EYisGhpgSCwspmIuRHGjROWTon2Xp8Z7U03Wubk/bTL5TTRC5R1rGVgyjzBrk9+ULdH6cRD06KRcw/xfqhVYKQ== is-plain-obj@^4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.0.0.tgz#06c0999fd7574edf5a906ba5644ad0feb3a84d22" - integrity sha512-NXRbBtUdBioI73y/HmOhogw/U5msYPC9DAtGkJXeFcFWSFZw0mCUsPxk/snTuJHzNKA8kLBK4rH97RMB1BfCXw== + version "4.1.0" + resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-4.1.0.tgz#d65025edec3657ce032fd7db63c97883eaed71f0" + integrity sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg== is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" @@ -13436,7 +13458,7 @@ is-reference@^1.2.1: is-reference@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/is-reference/-/is-reference-3.0.0.tgz#b1380c03d96ddf7089709781e3208fceb0c92cd6" + resolved "https://registry.yarnpkg.com/is-reference/-/is-reference-3.0.0.tgz#b1380c03d96ddf7089709781e3208fceb0c92cd6" integrity sha512-Eo1W3wUoHWoCoVM4GVl/a+K0IgiqE5aIo4kJABFyMum1ZORlPkC+UC357sSQUL5w5QCE5kCC9upl75b7+7CY/Q== dependencies: "@types/estree" "*" @@ -14613,7 +14635,7 @@ klaw@^1.0.0: optionalDependencies: graceful-fs "^4.1.9" -kleur@4.1.4, kleur@^4.0.3, kleur@^4.1.3: +kleur@4.1.4: version "4.1.4" resolved "https://registry.yarnpkg.com/kleur/-/kleur-4.1.4.tgz#8c202987d7e577766d039a8cd461934c01cda04d" integrity sha512-8QADVssbrFjivHWQU7KkMgptGTl6WAcSdlbBPY4uNF+mWr6DGcKrvY2w4FQJoXch7+fKMjj0dRrL75vk3k23OA== @@ -14623,6 +14645,11 @@ kleur@^3.0.2, kleur@^3.0.3: resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== +kleur@^4.0.3, kleur@^4.1.3: + version "4.1.5" + resolved "https://registry.yarnpkg.com/kleur/-/kleur-4.1.5.tgz#95106101795f7050c6c650f350c683febddb1780" + integrity sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ== + klona@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/klona/-/klona-2.0.4.tgz#7bb1e3affb0cb8624547ef7e8f6708ea2e39dfc0" @@ -15343,7 +15370,7 @@ longest-streak@^2.0.0, longest-streak@^2.0.1: longest-streak@^3.0.0: version "3.0.1" - resolved "https://registry.npmjs.org/longest-streak/-/longest-streak-3.0.1.tgz#c97315b7afa0e7d9525db9a5a2953651432bdc5d" + resolved "https://registry.yarnpkg.com/longest-streak/-/longest-streak-3.0.1.tgz#c97315b7afa0e7d9525db9a5a2953651432bdc5d" integrity sha512-cHlYSUpL2s7Fb3394mYxwTYj8niTaNHUCLr0qdiCXQfSjfuA7CKofpX2uSwEfFDQ0EB7JcnMnm+GjbqqoinYYg== loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: @@ -15676,13 +15703,13 @@ mdast-util-definitions@^4.0.0: unist-util-visit "^2.0.0" mdast-util-definitions@^5.0.0: - version "5.1.0" - resolved "https://registry.npmjs.org/mdast-util-definitions/-/mdast-util-definitions-5.1.0.tgz#b6d10ef00a3c4cf191e8d9a5fa58d7f4a366f817" - integrity sha512-5hcR7FL2EuZ4q6lLMUK5w4lHT2H3vqL9quPvYZ/Ku5iifrirfMHiGdhxdXMUbUkDmz5I+TYMd7nbaxUhbQkfpQ== + version "5.1.1" + resolved "https://registry.yarnpkg.com/mdast-util-definitions/-/mdast-util-definitions-5.1.1.tgz#2c1d684b28e53f84938bb06317944bee8efa79db" + integrity sha512-rQ+Gv7mHttxHOBx2dkF4HWTg+EE+UR78ptQWDylzPKaQuVGdG4HIoY3SrS/pCp80nZ04greFvXbVFHT+uf0JVQ== dependencies: "@types/mdast" "^3.0.0" "@types/unist" "^2.0.0" - unist-util-visit "^3.0.0" + unist-util-visit "^4.0.0" mdast-util-find-and-replace@^1.1.0: version "1.1.1" @@ -15714,7 +15741,7 @@ mdast-util-from-markdown@^0.8.0: mdast-util-from-markdown@^1.0.0: version "1.2.0" - resolved "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-1.2.0.tgz#84df2924ccc6c995dec1e2368b2b208ad0a76268" + resolved "https://registry.yarnpkg.com/mdast-util-from-markdown/-/mdast-util-from-markdown-1.2.0.tgz#84df2924ccc6c995dec1e2368b2b208ad0a76268" integrity sha512-iZJyyvKD1+K7QX1b5jXdE7Sc5dtoTry1vzV28UZZe8Z1xVnB/czKntJ7ZAkG0tANqRnBF6p3p7GpU1y19DTf2Q== dependencies: "@types/mdast" "^3.0.0" @@ -15800,22 +15827,22 @@ mdast-util-math@^0.1.0: repeat-string "^1.0.0" mdast-util-mdx-expression@^1.0.0: - version "1.2.0" - resolved "https://registry.npmjs.org/mdast-util-mdx-expression/-/mdast-util-mdx-expression-1.2.0.tgz#3e927afe27943956dc5d1c64cb949652062f71ff" - integrity sha512-wb36oi09XxqO9RVqgfD+xo8a7xaNgS+01+k3v0GKW0X0bYbeBmUZz22Z/IJ8SuphVlG+DNgNo9VoEaUJ3PKfJQ== + version "1.3.0" + resolved "https://registry.yarnpkg.com/mdast-util-mdx-expression/-/mdast-util-mdx-expression-1.3.0.tgz#fed063cc6320da1005c8e50338bb374d6dac69ba" + integrity sha512-9kTO13HaL/ChfzVCIEfDRdp1m5hsvsm6+R8yr67mH+KS2ikzZ0ISGLPTbTswOFpLLlgVHO9id3cul4ajutCvCA== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" "@types/hast" "^2.0.0" "@types/mdast" "^3.0.0" mdast-util-from-markdown "^1.0.0" mdast-util-to-markdown "^1.0.0" mdast-util-mdx-jsx@^2.0.0: - version "2.0.1" - resolved "https://registry.npmjs.org/mdast-util-mdx-jsx/-/mdast-util-mdx-jsx-2.0.1.tgz#03d003c8b0b4bd94ab092d876c0f92d2b0c83b0b" - integrity sha512-oPC7/smPBf7vxnvIYH5y3fPo2lw1rdrswFfSb4i0GTAXRUQv7JUU/t/hbp07dgGdUFTSDOHm5DNamhNg/s2Hrg== + version "2.1.0" + resolved "https://registry.yarnpkg.com/mdast-util-mdx-jsx/-/mdast-util-mdx-jsx-2.1.0.tgz#029f5a9c38485dbb5cf482059557ee7d788f1947" + integrity sha512-KzgzfWMhdteDkrY4mQtyvTU5bc/W4ppxhe9SzelO6QUUiwLAM+Et2Dnjjprik74a336kHdo0zKm7Tp+n6FFeRg== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" "@types/hast" "^2.0.0" "@types/mdast" "^3.0.0" ccount "^2.0.0" @@ -15828,7 +15855,7 @@ mdast-util-mdx-jsx@^2.0.0: mdast-util-mdx@^2.0.0: version "2.0.0" - resolved "https://registry.npmjs.org/mdast-util-mdx/-/mdast-util-mdx-2.0.0.tgz#dd4f6c993cf27da32725e50a04874f595b7b63fb" + resolved "https://registry.yarnpkg.com/mdast-util-mdx/-/mdast-util-mdx-2.0.0.tgz#dd4f6c993cf27da32725e50a04874f595b7b63fb" integrity sha512-M09lW0CcBT1VrJUaF/PYxemxxHa7SLDHdSn94Q9FhxjCQfuW7nMAWKWimTmA3OyDMSTH981NN1csW1X+HPSluw== dependencies: mdast-util-mdx-expression "^1.0.0" @@ -15836,11 +15863,11 @@ mdast-util-mdx@^2.0.0: mdast-util-mdxjs-esm "^1.0.0" mdast-util-mdxjs-esm@^1.0.0: - version "1.2.0" - resolved "https://registry.npmjs.org/mdast-util-mdxjs-esm/-/mdast-util-mdxjs-esm-1.2.0.tgz#eca8b985f091c2d65a72c19d2740cefbc209aa63" - integrity sha512-IPpX9GBzAIbIRCjbyeLDpMhACFb0wxTIujuR3YElB8LWbducUdMgRJuqs/Vg8xQ1bIAMm7lw8L+YNtua0xKXRw== + version "1.3.0" + resolved "https://registry.yarnpkg.com/mdast-util-mdxjs-esm/-/mdast-util-mdxjs-esm-1.3.0.tgz#137345ef827169aeeeb6069277cd3e090830ce9a" + integrity sha512-7N5ihsOkAEGjFotIX9p/YPdl4TqUoMxL4ajNz7PbT89BqsdWJuBC9rvgt6wpbwTZqWWR0jKWqQbwsOWDBUZv4g== dependencies: - "@types/estree-jsx" "^0.0.1" + "@types/estree-jsx" "^1.0.0" "@types/hast" "^2.0.0" "@types/mdast" "^3.0.0" mdast-util-from-markdown "^1.0.0" @@ -15861,9 +15888,9 @@ mdast-util-to-hast@^10.2.0: unist-util-visit "^2.0.0" mdast-util-to-hast@^12.1.0: - version "12.1.1" - resolved "https://registry.npmjs.org/mdast-util-to-hast/-/mdast-util-to-hast-12.1.1.tgz#89a2bb405eaf3b05eb8bf45157678f35eef5dbca" - integrity sha512-qE09zD6ylVP14jV4mjLIhDBOrpFdShHZcEsYvvKGABlr9mGbV7mTlRWdoFxL/EYSTNDiC9GZXy7y8Shgb9Dtzw== + version "12.2.2" + resolved "https://registry.yarnpkg.com/mdast-util-to-hast/-/mdast-util-to-hast-12.2.2.tgz#2bd8cf985a67c90c181eadcfdd8d31b8798ed9a1" + integrity sha512-lVkUttV9wqmdXFtEBXKcepvU/zfwbhjbkM5rxrquLW55dS1DfOrnAXCk5mg1be1sfY/WfMmayGy1NsbK1GLCYQ== dependencies: "@types/hast" "^2.0.0" "@types/mdast" "^3.0.0" @@ -15871,6 +15898,7 @@ mdast-util-to-hast@^12.1.0: mdast-util-definitions "^5.0.0" mdurl "^1.0.0" micromark-util-sanitize-uri "^1.0.0" + trim-lines "^3.0.0" unist-builder "^3.0.0" unist-util-generated "^2.0.0" unist-util-position "^4.0.0" @@ -15907,7 +15935,7 @@ mdast-util-to-markdown@^0.6.0, mdast-util-to-markdown@^0.6.1, mdast-util-to-mark mdast-util-to-markdown@^1.0.0, mdast-util-to-markdown@^1.3.0: version "1.3.0" - resolved "https://registry.npmjs.org/mdast-util-to-markdown/-/mdast-util-to-markdown-1.3.0.tgz#38b6cdc8dc417de642a469c4fc2abdf8c931bd1e" + resolved "https://registry.yarnpkg.com/mdast-util-to-markdown/-/mdast-util-to-markdown-1.3.0.tgz#38b6cdc8dc417de642a469c4fc2abdf8c931bd1e" integrity sha512-6tUSs4r+KK4JGTTiQ7FfHmVOaDrLQJPmpjD6wPMlHGUVXoG9Vjc3jIeP+uyBWRf8clwB2blM+W7+KrlMYQnftA== dependencies: "@types/mdast" "^3.0.0" @@ -15940,7 +15968,7 @@ mdast-util-to-string@^2.0.0: mdast-util-to-string@^3.0.0, mdast-util-to-string@^3.1.0: version "3.1.0" - resolved "https://registry.npmjs.org/mdast-util-to-string/-/mdast-util-to-string-3.1.0.tgz#56c506d065fbf769515235e577b5a261552d56e9" + resolved "https://registry.yarnpkg.com/mdast-util-to-string/-/mdast-util-to-string-3.1.0.tgz#56c506d065fbf769515235e577b5a261552d56e9" integrity sha512-n4Vypz/DZgwo0iMHLQL49dJzlp7YtAJP+N07MZHpjPf/5XJuHUWstviF4Mn2jEiR/GNmtnRRqnwsXExk3igfFA== mdast-util-toc@^2.0.0: @@ -16210,7 +16238,7 @@ microbundle@^0.15.0, microbundle@^0.15.1: micromark-core-commonmark@^1.0.0, micromark-core-commonmark@^1.0.1: version "1.0.6" - resolved "https://registry.npmjs.org/micromark-core-commonmark/-/micromark-core-commonmark-1.0.6.tgz#edff4c72e5993d93724a3c206970f5a15b0585ad" + resolved "https://registry.yarnpkg.com/micromark-core-commonmark/-/micromark-core-commonmark-1.0.6.tgz#edff4c72e5993d93724a3c206970f5a15b0585ad" integrity sha512-K+PkJTxqjFfSNkfAhp4GB+cZPfQd6dxtTXnf+RjZOV7T4EEXnvgzOcnp+eSTmpGk9d1S9sL6/lqrgSNn/s0HZA== dependencies: decode-named-character-reference "^1.0.0" @@ -16299,7 +16327,7 @@ micromark-extension-math@^0.1.0: micromark-extension-mdx-expression@^1.0.0: version "1.0.3" - resolved "https://registry.npmjs.org/micromark-extension-mdx-expression/-/micromark-extension-mdx-expression-1.0.3.tgz#cd3843573921bf55afcfff4ae0cd2e857a16dcfa" + resolved "https://registry.yarnpkg.com/micromark-extension-mdx-expression/-/micromark-extension-mdx-expression-1.0.3.tgz#cd3843573921bf55afcfff4ae0cd2e857a16dcfa" integrity sha512-TjYtjEMszWze51NJCZmhv7MEBcgYRgb3tJeMAJ+HQCAaZHHRBaDCccqQzGizR/H4ODefP44wRTgOn2vE5I6nZA== dependencies: micromark-factory-mdx-expression "^1.0.0" @@ -16312,7 +16340,7 @@ micromark-extension-mdx-expression@^1.0.0: micromark-extension-mdx-jsx@^1.0.0: version "1.0.3" - resolved "https://registry.npmjs.org/micromark-extension-mdx-jsx/-/micromark-extension-mdx-jsx-1.0.3.tgz#9f196be5f65eb09d2a49b237a7b3398bba2999be" + resolved "https://registry.yarnpkg.com/micromark-extension-mdx-jsx/-/micromark-extension-mdx-jsx-1.0.3.tgz#9f196be5f65eb09d2a49b237a7b3398bba2999be" integrity sha512-VfA369RdqUISF0qGgv2FfV7gGjHDfn9+Qfiv5hEwpyr1xscRj/CiVRkU7rywGFCO7JwJ5L0e7CJz60lY52+qOA== dependencies: "@types/acorn" "^4.0.0" @@ -16327,14 +16355,14 @@ micromark-extension-mdx-jsx@^1.0.0: micromark-extension-mdx-md@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-extension-mdx-md/-/micromark-extension-mdx-md-1.0.0.tgz#382f5df9ee3706dd120b51782a211f31f4760d22" + resolved "https://registry.yarnpkg.com/micromark-extension-mdx-md/-/micromark-extension-mdx-md-1.0.0.tgz#382f5df9ee3706dd120b51782a211f31f4760d22" integrity sha512-xaRAMoSkKdqZXDAoSgp20Azm0aRQKGOl0RrS81yGu8Hr/JhMsBmfs4wR7m9kgVUIO36cMUQjNyiyDKPrsv8gOw== dependencies: micromark-util-types "^1.0.0" micromark-extension-mdxjs-esm@^1.0.0: version "1.0.3" - resolved "https://registry.npmjs.org/micromark-extension-mdxjs-esm/-/micromark-extension-mdxjs-esm-1.0.3.tgz#630d9dc9db2c2fd470cac8c1e7a824851267404d" + resolved "https://registry.yarnpkg.com/micromark-extension-mdxjs-esm/-/micromark-extension-mdxjs-esm-1.0.3.tgz#630d9dc9db2c2fd470cac8c1e7a824851267404d" integrity sha512-2N13ol4KMoxb85rdDwTAC6uzs8lMX0zeqpcyx7FhS7PxXomOnLactu8WI8iBNXW8AVyea3KIJd/1CKnUmwrK9A== dependencies: micromark-core-commonmark "^1.0.0" @@ -16348,7 +16376,7 @@ micromark-extension-mdxjs-esm@^1.0.0: micromark-extension-mdxjs@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-extension-mdxjs/-/micromark-extension-mdxjs-1.0.0.tgz#772644e12fc8299a33e50f59c5aa15727f6689dd" + resolved "https://registry.yarnpkg.com/micromark-extension-mdxjs/-/micromark-extension-mdxjs-1.0.0.tgz#772644e12fc8299a33e50f59c5aa15727f6689dd" integrity sha512-TZZRZgeHvtgm+IhtgC2+uDMR7h8eTKF0QUX9YsgoL9+bADBpBY6SiLvWqnBlLbCEevITmTqmEuY3FoxMKVs1rQ== dependencies: acorn "^8.0.0" @@ -16362,7 +16390,7 @@ micromark-extension-mdxjs@^1.0.0: micromark-factory-destination@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-factory-destination/-/micromark-factory-destination-1.0.0.tgz#fef1cb59ad4997c496f887b6977aa3034a5a277e" + resolved "https://registry.yarnpkg.com/micromark-factory-destination/-/micromark-factory-destination-1.0.0.tgz#fef1cb59ad4997c496f887b6977aa3034a5a277e" integrity sha512-eUBA7Rs1/xtTVun9TmV3gjfPz2wEwgK5R5xcbIM5ZYAtvGF6JkyaDsj0agx8urXnO31tEO6Ug83iVH3tdedLnw== dependencies: micromark-util-character "^1.0.0" @@ -16371,7 +16399,7 @@ micromark-factory-destination@^1.0.0: micromark-factory-label@^1.0.0: version "1.0.2" - resolved "https://registry.npmjs.org/micromark-factory-label/-/micromark-factory-label-1.0.2.tgz#6be2551fa8d13542fcbbac478258fb7a20047137" + resolved "https://registry.yarnpkg.com/micromark-factory-label/-/micromark-factory-label-1.0.2.tgz#6be2551fa8d13542fcbbac478258fb7a20047137" integrity sha512-CTIwxlOnU7dEshXDQ+dsr2n+yxpP0+fn271pu0bwDIS8uqfFcumXpj5mLn3hSC8iw2MUr6Gx8EcKng1dD7i6hg== dependencies: micromark-util-character "^1.0.0" @@ -16381,7 +16409,7 @@ micromark-factory-label@^1.0.0: micromark-factory-mdx-expression@^1.0.0: version "1.0.6" - resolved "https://registry.npmjs.org/micromark-factory-mdx-expression/-/micromark-factory-mdx-expression-1.0.6.tgz#917e17d16e6e9c2551f3a862e6a9ebdd22056476" + resolved "https://registry.yarnpkg.com/micromark-factory-mdx-expression/-/micromark-factory-mdx-expression-1.0.6.tgz#917e17d16e6e9c2551f3a862e6a9ebdd22056476" integrity sha512-WRQIc78FV7KrCfjsEf/sETopbYjElh3xAmNpLkd1ODPqxEngP42eVRGbiPEQWpRV27LzqW+XVTvQAMIIRLPnNA== dependencies: micromark-factory-space "^1.0.0" @@ -16395,7 +16423,7 @@ micromark-factory-mdx-expression@^1.0.0: micromark-factory-space@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-factory-space/-/micromark-factory-space-1.0.0.tgz#cebff49968f2b9616c0fcb239e96685cb9497633" + resolved "https://registry.yarnpkg.com/micromark-factory-space/-/micromark-factory-space-1.0.0.tgz#cebff49968f2b9616c0fcb239e96685cb9497633" integrity sha512-qUmqs4kj9a5yBnk3JMLyjtWYN6Mzfcx8uJfi5XAveBniDevmZasdGBba5b4QsvRcAkmvGo5ACmSUmyGiKTLZew== dependencies: micromark-util-character "^1.0.0" @@ -16403,7 +16431,7 @@ micromark-factory-space@^1.0.0: micromark-factory-title@^1.0.0: version "1.0.2" - resolved "https://registry.npmjs.org/micromark-factory-title/-/micromark-factory-title-1.0.2.tgz#7e09287c3748ff1693930f176e1c4a328382494f" + resolved "https://registry.yarnpkg.com/micromark-factory-title/-/micromark-factory-title-1.0.2.tgz#7e09287c3748ff1693930f176e1c4a328382494f" integrity sha512-zily+Nr4yFqgMGRKLpTVsNl5L4PMu485fGFDOQJQBl2NFpjGte1e86zC0da93wf97jrc4+2G2GQudFMHn3IX+A== dependencies: micromark-factory-space "^1.0.0" @@ -16414,7 +16442,7 @@ micromark-factory-title@^1.0.0: micromark-factory-whitespace@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-factory-whitespace/-/micromark-factory-whitespace-1.0.0.tgz#e991e043ad376c1ba52f4e49858ce0794678621c" + resolved "https://registry.yarnpkg.com/micromark-factory-whitespace/-/micromark-factory-whitespace-1.0.0.tgz#e991e043ad376c1ba52f4e49858ce0794678621c" integrity sha512-Qx7uEyahU1lt1RnsECBiuEbfr9INjQTGa6Err+gF3g0Tx4YEviPbqqGKNv/NrBaE7dVHdn1bVZKM/n5I/Bak7A== dependencies: micromark-factory-space "^1.0.0" @@ -16424,7 +16452,7 @@ micromark-factory-whitespace@^1.0.0: micromark-util-character@^1.0.0: version "1.1.0" - resolved "https://registry.npmjs.org/micromark-util-character/-/micromark-util-character-1.1.0.tgz#d97c54d5742a0d9611a68ca0cd4124331f264d86" + resolved "https://registry.yarnpkg.com/micromark-util-character/-/micromark-util-character-1.1.0.tgz#d97c54d5742a0d9611a68ca0cd4124331f264d86" integrity sha512-agJ5B3unGNJ9rJvADMJ5ZiYjBRyDpzKAOk01Kpi1TKhlT1APx3XZk6eN7RtSz1erbWHC2L8T3xLZ81wdtGRZzg== dependencies: micromark-util-symbol "^1.0.0" @@ -16432,14 +16460,14 @@ micromark-util-character@^1.0.0: micromark-util-chunked@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-chunked/-/micromark-util-chunked-1.0.0.tgz#5b40d83f3d53b84c4c6bce30ed4257e9a4c79d06" + resolved "https://registry.yarnpkg.com/micromark-util-chunked/-/micromark-util-chunked-1.0.0.tgz#5b40d83f3d53b84c4c6bce30ed4257e9a4c79d06" integrity sha512-5e8xTis5tEZKgesfbQMKRCyzvffRRUX+lK/y+DvsMFdabAicPkkZV6gO+FEWi9RfuKKoxxPwNL+dFF0SMImc1g== dependencies: micromark-util-symbol "^1.0.0" micromark-util-classify-character@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-classify-character/-/micromark-util-classify-character-1.0.0.tgz#cbd7b447cb79ee6997dd274a46fc4eb806460a20" + resolved "https://registry.yarnpkg.com/micromark-util-classify-character/-/micromark-util-classify-character-1.0.0.tgz#cbd7b447cb79ee6997dd274a46fc4eb806460a20" integrity sha512-F8oW2KKrQRb3vS5ud5HIqBVkCqQi224Nm55o5wYLzY/9PwHGXC01tr3d7+TqHHz6zrKQ72Okwtvm/xQm6OVNZA== dependencies: micromark-util-character "^1.0.0" @@ -16448,7 +16476,7 @@ micromark-util-classify-character@^1.0.0: micromark-util-combine-extensions@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-combine-extensions/-/micromark-util-combine-extensions-1.0.0.tgz#91418e1e74fb893e3628b8d496085639124ff3d5" + resolved "https://registry.yarnpkg.com/micromark-util-combine-extensions/-/micromark-util-combine-extensions-1.0.0.tgz#91418e1e74fb893e3628b8d496085639124ff3d5" integrity sha512-J8H058vFBdo/6+AsjHp2NF7AJ02SZtWaVUjsayNFeAiydTxUwViQPxN0Hf8dp4FmCQi0UUFovFsEyRSUmFH3MA== dependencies: micromark-util-chunked "^1.0.0" @@ -16456,14 +16484,14 @@ micromark-util-combine-extensions@^1.0.0: micromark-util-decode-numeric-character-reference@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-decode-numeric-character-reference/-/micromark-util-decode-numeric-character-reference-1.0.0.tgz#dcc85f13b5bd93ff8d2868c3dba28039d490b946" + resolved "https://registry.yarnpkg.com/micromark-util-decode-numeric-character-reference/-/micromark-util-decode-numeric-character-reference-1.0.0.tgz#dcc85f13b5bd93ff8d2868c3dba28039d490b946" integrity sha512-OzO9AI5VUtrTD7KSdagf4MWgHMtET17Ua1fIpXTpuhclCqD8egFWo85GxSGvxgkGS74bEahvtM0WP0HjvV0e4w== dependencies: micromark-util-symbol "^1.0.0" micromark-util-decode-string@^1.0.0: version "1.0.2" - resolved "https://registry.npmjs.org/micromark-util-decode-string/-/micromark-util-decode-string-1.0.2.tgz#942252ab7a76dec2dbf089cc32505ee2bc3acf02" + resolved "https://registry.yarnpkg.com/micromark-util-decode-string/-/micromark-util-decode-string-1.0.2.tgz#942252ab7a76dec2dbf089cc32505ee2bc3acf02" integrity sha512-DLT5Ho02qr6QWVNYbRZ3RYOSSWWFuH3tJexd3dgN1odEuPNxCngTCXJum7+ViRAd9BbdxCvMToPOD/IvVhzG6Q== dependencies: decode-named-character-reference "^1.0.0" @@ -16473,16 +16501,16 @@ micromark-util-decode-string@^1.0.0: micromark-util-encode@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/micromark-util-encode/-/micromark-util-encode-1.0.1.tgz#2c1c22d3800870ad770ece5686ebca5920353383" + resolved "https://registry.yarnpkg.com/micromark-util-encode/-/micromark-util-encode-1.0.1.tgz#2c1c22d3800870ad770ece5686ebca5920353383" integrity sha512-U2s5YdnAYexjKDel31SVMPbfi+eF8y1U4pfiRW/Y8EFVCy/vgxk/2wWTxzcqE71LHtCuCzlBDRU2a5CQ5j+mQA== micromark-util-events-to-acorn@^1.0.0: - version "1.1.0" - resolved "https://registry.npmjs.org/micromark-util-events-to-acorn/-/micromark-util-events-to-acorn-1.1.0.tgz#9891638e201c266484d0af7cd2505d208f73db9d" - integrity sha512-hB8HzidNt/Us5q2BvqXj8eeEm0U9rRfnZxcA9T65JRUMAY4MbfJRAFm7m9fXMAdSHJiVPmajsp8/rp6/FlHL8A== + version "1.2.0" + resolved "https://registry.yarnpkg.com/micromark-util-events-to-acorn/-/micromark-util-events-to-acorn-1.2.0.tgz#65785cb77299d791bfefdc6a5213ab57ceead115" + integrity sha512-WWp3bf7xT9MppNuw3yPjpnOxa8cj5ACivEzXJKu0WwnjBYfzaBvIAT9KfeyI0Qkll+bfQtfftSwdgTH6QhTOKw== dependencies: "@types/acorn" "^4.0.0" - "@types/estree" "^0.0.51" + "@types/estree" "^1.0.0" estree-util-visit "^1.0.0" micromark-util-types "^1.0.0" uvu "^0.5.0" @@ -16490,27 +16518,27 @@ micromark-util-events-to-acorn@^1.0.0: vfile-message "^3.0.0" micromark-util-html-tag-name@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-html-tag-name/-/micromark-util-html-tag-name-1.0.0.tgz#75737e92fef50af0c6212bd309bc5cb8dbd489ed" - integrity sha512-NenEKIshW2ZI/ERv9HtFNsrn3llSPZtY337LID/24WeLqMzeZhBEE6BQ0vS2ZBjshm5n40chKtJ3qjAbVV8S0g== + version "1.1.0" + resolved "https://registry.yarnpkg.com/micromark-util-html-tag-name/-/micromark-util-html-tag-name-1.1.0.tgz#eb227118befd51f48858e879b7a419fc0df20497" + integrity sha512-BKlClMmYROy9UiV03SwNmckkjn8QHVaWkqoAqzivabvdGcwNGMMMH/5szAnywmsTBUzDsU57/mFi0sp4BQO6dA== micromark-util-normalize-identifier@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-1.0.0.tgz#4a3539cb8db954bbec5203952bfe8cedadae7828" + resolved "https://registry.yarnpkg.com/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-1.0.0.tgz#4a3539cb8db954bbec5203952bfe8cedadae7828" integrity sha512-yg+zrL14bBTFrQ7n35CmByWUTFsgst5JhA4gJYoty4Dqzj4Z4Fr/DHekSS5aLfH9bdlfnSvKAWsAgJhIbogyBg== dependencies: micromark-util-symbol "^1.0.0" micromark-util-resolve-all@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-resolve-all/-/micromark-util-resolve-all-1.0.0.tgz#a7c363f49a0162e931960c44f3127ab58f031d88" + resolved "https://registry.yarnpkg.com/micromark-util-resolve-all/-/micromark-util-resolve-all-1.0.0.tgz#a7c363f49a0162e931960c44f3127ab58f031d88" integrity sha512-CB/AGk98u50k42kvgaMM94wzBqozSzDDaonKU7P7jwQIuH2RU0TeBqGYJz2WY1UdihhjweivStrJ2JdkdEmcfw== dependencies: micromark-util-types "^1.0.0" micromark-util-sanitize-uri@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-1.0.0.tgz#27dc875397cd15102274c6c6da5585d34d4f12b2" + resolved "https://registry.yarnpkg.com/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-1.0.0.tgz#27dc875397cd15102274c6c6da5585d34d4f12b2" integrity sha512-cCxvBKlmac4rxCGx6ejlIviRaMKZc0fWm5HdCHEeDWRSkn44l6NdYVRyU+0nT1XC72EQJMZV8IPHF+jTr56lAg== dependencies: micromark-util-character "^1.0.0" @@ -16519,7 +16547,7 @@ micromark-util-sanitize-uri@^1.0.0: micromark-util-subtokenize@^1.0.0: version "1.0.2" - resolved "https://registry.npmjs.org/micromark-util-subtokenize/-/micromark-util-subtokenize-1.0.2.tgz#ff6f1af6ac836f8bfdbf9b02f40431760ad89105" + resolved "https://registry.yarnpkg.com/micromark-util-subtokenize/-/micromark-util-subtokenize-1.0.2.tgz#ff6f1af6ac836f8bfdbf9b02f40431760ad89105" integrity sha512-d90uqCnXp/cy4G881Ub4psE57Sf8YD0pim9QdjCRNjfas2M1u6Lbt+XZK9gnHL2XFhnozZiEdCa9CNfXSfQ6xA== dependencies: micromark-util-chunked "^1.0.0" @@ -16529,12 +16557,12 @@ micromark-util-subtokenize@^1.0.0: micromark-util-symbol@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/micromark-util-symbol/-/micromark-util-symbol-1.0.1.tgz#b90344db62042ce454f351cf0bebcc0a6da4920e" + resolved "https://registry.yarnpkg.com/micromark-util-symbol/-/micromark-util-symbol-1.0.1.tgz#b90344db62042ce454f351cf0bebcc0a6da4920e" integrity sha512-oKDEMK2u5qqAptasDAwWDXq0tG9AssVwAx3E9bBF3t/shRIGsWIRG+cGafs2p/SnDSOecnt6hZPCE2o6lHfFmQ== micromark-util-types@^1.0.0, micromark-util-types@^1.0.1: version "1.0.2" - resolved "https://registry.npmjs.org/micromark-util-types/-/micromark-util-types-1.0.2.tgz#f4220fdb319205812f99c40f8c87a9be83eded20" + resolved "https://registry.yarnpkg.com/micromark-util-types/-/micromark-util-types-1.0.2.tgz#f4220fdb319205812f99c40f8c87a9be83eded20" integrity sha512-DCfg/T8fcrhrRKTPjRrw/5LLvdGV7BHySf/1LOZx7TzWZdYRjogNtyNq885z3nNallwr3QUKARjqvHqX1/7t+w== micromark@^2.11.3, micromark@~2.11.0, micromark@~2.11.3: @@ -16547,7 +16575,7 @@ micromark@^2.11.3, micromark@~2.11.0, micromark@~2.11.3: micromark@^3.0.0: version "3.0.10" - resolved "https://registry.npmjs.org/micromark/-/micromark-3.0.10.tgz#1eac156f0399d42736458a14b0ca2d86190b457c" + resolved "https://registry.yarnpkg.com/micromark/-/micromark-3.0.10.tgz#1eac156f0399d42736458a14b0ca2d86190b457c" integrity sha512-ryTDy6UUunOXy2HPjelppgJ2sNfcPz1pLlMdA6Rz9jPzhLikWXv/irpWV/I2jd68Uhmny7hHxAlAhk4+vWggpg== dependencies: "@types/debug" "^4.0.0" @@ -18114,7 +18142,7 @@ parse-entities@^2.0.0: parse-entities@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/parse-entities/-/parse-entities-4.0.0.tgz#f67c856d4e3fe19b1a445c3fabe78dcdc1053eeb" + resolved "https://registry.yarnpkg.com/parse-entities/-/parse-entities-4.0.0.tgz#f67c856d4e3fe19b1a445c3fabe78dcdc1053eeb" integrity sha512-5nk9Fn03x3rEhGaX1FU6IDwG/k+GxLXlFAkgrbM1asuAFl3BhdQWvASaIsmwWypRNcZKHPYnIuOSfIWEyEQnPQ== dependencies: "@types/unist" "^2.0.0" @@ -18456,7 +18484,7 @@ performance-now@^2.1.0: periscopic@^3.0.0: version "3.0.4" - resolved "https://registry.npmjs.org/periscopic/-/periscopic-3.0.4.tgz#b3fbed0d1bc844976b977173ca2cd4a0ef4fa8d1" + resolved "https://registry.yarnpkg.com/periscopic/-/periscopic-3.0.4.tgz#b3fbed0d1bc844976b977173ca2cd4a0ef4fa8d1" integrity sha512-SFx68DxCv0Iyo6APZuw/AKewkkThGwssmU0QWtTlvov3VAtPX+QJ4CadwSaz8nrT5jPIuxdvJWB4PnD2KNDxQg== dependencies: estree-walker "^3.0.0" @@ -19538,7 +19566,7 @@ property-information@^5.0.0, property-information@^5.0.1, property-information@^ property-information@^6.0.0: version "6.1.1" - resolved "https://registry.npmjs.org/property-information/-/property-information-6.1.1.tgz#5ca85510a3019726cb9afed4197b7b8ac5926a22" + resolved "https://registry.yarnpkg.com/property-information/-/property-information-6.1.1.tgz#5ca85510a3019726cb9afed4197b7b8ac5926a22" integrity sha512-hrzC564QIl0r0vy4l6MvRLhafmUowhO/O3KgVSoXIbbA2Sz4j8HGpJc6T2cubRVwMwpdiG/vKGfhT4IixmKN9w== proto-list@~1.2.1: @@ -19899,10 +19927,19 @@ react-reconciler@^0.26.2: object-assign "^4.1.1" scheduler "^0.20.2" -react-refresh@^0.14.0: - version "0.14.0" - resolved "https://registry.yarnpkg.com/react-refresh/-/react-refresh-0.14.0.tgz#4e02825378a5f227079554d4284889354e5f553e" - integrity sha512-wViHqhAd8OHeLS/IRMJjTSDHF3U9eWi62F/MledQGPdJGDhodXJ9PBLNGr6WWL7qlH12Mt3TyTpbS+hGXMjCzQ== +react-refresh@^0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/react-refresh/-/react-refresh-0.9.0.tgz#71863337adc3e5c2f8a6bfddd12ae3bfe32aafbf" + integrity sha512-Gvzk7OZpiqKSkxsQvO/mbTN1poglhmAV7gR/DdIrRrSMXraRQQlfikRJOr3Nb9GTMPC5kof948Zy6jJZIFtDvQ== + +react-server-dom-webpack@0.0.0-experimental-c8b778b7f-20220825: + version "0.0.0-experimental-c8b778b7f-20220825" + resolved "https://registry.yarnpkg.com/react-server-dom-webpack/-/react-server-dom-webpack-0.0.0-experimental-c8b778b7f-20220825.tgz#b147886ed7cff5b31d9452d6ffe6987bfd876ceb" + integrity sha512-JyCjbp6ZvkH/T0EuVPdceYlC8u5WqWDSJr2KxDvc81H2eJ+7zYUN++IcEycnR2F+HmER8QVgxfotnIx352zi+w== + dependencies: + acorn "^6.2.1" + loose-envify "^1.1.0" + neo-async "^2.6.1" react-test-renderer@^16.14.0: version "16.14.0" @@ -20997,9 +21034,9 @@ remark-mdx@^1.6.22: unified "9.2.0" remark-mdx@^2.0.0: - version "2.1.1" - resolved "https://registry.npmjs.org/remark-mdx/-/remark-mdx-2.1.1.tgz#14021be9ecbc9ad0310f4240980221328aa7ed55" - integrity sha512-0wXdEITnFyjLquN3VvACNLzbGzWM5ujzTvfgOkONBZgSFJ7ezLLDaTWqf6H9eUgVITEP8asp6LJ0W/X090dXBg== + version "2.1.3" + resolved "https://registry.yarnpkg.com/remark-mdx/-/remark-mdx-2.1.3.tgz#6273e8b94d27ade35407a63bc8cdd04592f7be9f" + integrity sha512-3SmtXOy9+jIaVctL8Cs3VAQInjRLGOwNXfrBB9KCT+EpJpKD3PQiy0x8hUNGyjQmdyOs40BqgPU7kYtH9uoR6w== dependencies: mdast-util-mdx "^2.0.0" micromark-extension-mdxjs "^1.0.0" @@ -21151,7 +21188,7 @@ remark-reference-links@^4.0.1: remark-rehype@^10.0.0: version "10.1.0" - resolved "https://registry.npmjs.org/remark-rehype/-/remark-rehype-10.1.0.tgz#32dc99d2034c27ecaf2e0150d22a6dcccd9a6279" + resolved "https://registry.yarnpkg.com/remark-rehype/-/remark-rehype-10.1.0.tgz#32dc99d2034c27ecaf2e0150d22a6dcccd9a6279" integrity sha512-EFmR5zppdBp0WQeDVZ/b66CWJipB2q2VLNFMabzDSGR66Z2fQii83G5gTBbgGEnEEA0QRussvrFHxk1HWGJskw== dependencies: "@types/hast" "^2.0.0" @@ -22511,9 +22548,10 @@ source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6, source-map@^0.5.7: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" -source-map@^0.7.3, source-map@~0.7.2: - version "0.7.3" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" +source-map@^0.7.0, source-map@^0.7.3, source-map@~0.7.2: + version "0.7.4" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656" + integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA== source-map@~0.1.30: version "0.1.43" @@ -22533,7 +22571,7 @@ space-separated-tokens@^1.0.0, space-separated-tokens@^1.1.5: space-separated-tokens@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/space-separated-tokens/-/space-separated-tokens-2.0.1.tgz#43193cec4fb858a2ce934b7f98b7f2c18107098b" + resolved "https://registry.yarnpkg.com/space-separated-tokens/-/space-separated-tokens-2.0.1.tgz#43193cec4fb858a2ce934b7f98b7f2c18107098b" integrity sha512-ekwEbFp5aqSPKaqeY1PGrlGQxPNaq+Cnx4+bE2D8sciBQrHpbwoBbawqTN2+6jPs9IdWxxiUcN0K2pkczD3zmw== sparse-bitfield@^3.0.3: @@ -22975,9 +23013,9 @@ stringify-entities@^3.0.1: is-hexadecimal "^1.0.0" stringify-entities@^4.0.0: - version "4.0.2" - resolved "https://registry.npmjs.org/stringify-entities/-/stringify-entities-4.0.2.tgz#13d113dc7449dc8ae4cb22c28883ee3fff8753e3" - integrity sha512-MTxTVcEkorNtBbNpoFJPEh0kKdM6+QbMjLbaxmvaPMmayOXdr/AIVIIJX7FReUVweRBFJfZepK4A4AKgwuFpMQ== + version "4.0.3" + resolved "https://registry.yarnpkg.com/stringify-entities/-/stringify-entities-4.0.3.tgz#cfabd7039d22ad30f3cc435b0ca2c1574fc88ef8" + integrity sha512-BP9nNHMhhfcMbiuQKCqMjhDP5yBCAxsPu4pHFFzJ6Alo9dZgY4VLDPutXqIjpRiMoKdp7Av85Gr73Q5uH9k7+g== dependencies: character-entities-html4 "^2.0.0" character-entities-legacy "^3.0.0" @@ -23911,6 +23949,11 @@ trim-lines@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/trim-lines/-/trim-lines-1.1.1.tgz#da738ff58fa74817588455e30b11b85289f2a396" +trim-lines@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/trim-lines/-/trim-lines-3.0.1.tgz#d802e332a07df861c48802c04321017b1bd87338" + integrity sha512-kRj8B+YHZCc9kQYdWfJB2/oUl9rA99qbowYYBtr4ui4mZyAQ2JpvVBd/6U2YloATfqBhBTSMhTpgBHtU0Mf3Rg== + trim-newlines@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-1.0.0.tgz#5887966bb582a4503a41eb524f7d35011815a613" @@ -23953,7 +23996,7 @@ trough@^1.0.0: trough@^2.0.0: version "2.1.0" - resolved "https://registry.npmjs.org/trough/-/trough-2.1.0.tgz#0f7b511a4fde65a46f18477ab38849b22c554876" + resolved "https://registry.yarnpkg.com/trough/-/trough-2.1.0.tgz#0f7b511a4fde65a46f18477ab38849b22c554876" integrity sha512-AqTiAOLcj85xS7vQ8QkAV41hPDIJ71XJB4RCUrzo/1GM2CQwhkJGaf9Hgr7BOugMRpgGUrqRg/DrBDl4H40+8g== "true-case-path@^2.2.1": @@ -24132,9 +24175,9 @@ typedarray@^0.0.6, typedarray@~0.0.5: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" typescript@^4.1.3, typescript@^4.7.4: - version "4.7.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.4.tgz#1a88596d1cf47d59507a1bcdfb5b9dfe4d488235" - integrity sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ== + version "4.8.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.8.3.tgz#d59344522c4bc464a65a730ac695007fdb66dd88" + integrity sha512-goMHfm00nWPa8UvR/CPSvykqf6dVV8x/dp0c5mFTMTIu0u0FlGWRioyy7Nn0PGAdHxpJZnuO/ut+PpQ8UiHAig== typography-normalize@^0.16.19: version "0.16.19" @@ -24320,7 +24363,7 @@ unified@9.2.0: unified@^10.0.0, unified@^10.1.2: version "10.1.2" - resolved "https://registry.npmjs.org/unified/-/unified-10.1.2.tgz#b1d64e55dafe1f0b98bb6c719881103ecf6c86df" + resolved "https://registry.yarnpkg.com/unified/-/unified-10.1.2.tgz#b1d64e55dafe1f0b98bb6c719881103ecf6c86df" integrity sha512-pUSWAi/RAnVy1Pif2kAoeWNBa3JVrx0MId2LASj8G+7AiHWoKZNTomq6LG326T68U7/e263X6fTdcXIy7XnF7Q== dependencies: "@types/unist" "^2.0.0" @@ -24429,7 +24472,7 @@ unist-builder@^2.0.0: unist-builder@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/unist-builder/-/unist-builder-3.0.0.tgz#728baca4767c0e784e1e64bb44b5a5a753021a04" + resolved "https://registry.yarnpkg.com/unist-builder/-/unist-builder-3.0.0.tgz#728baca4767c0e784e1e64bb44b5a5a753021a04" integrity sha512-GFxmfEAa0vi9i5sd0R2kcrI9ks0r82NasRq5QHh2ysGngrc6GiqD5CDf1FjPenY4vApmFASBIIlk/jj5J5YbmQ== dependencies: "@types/unist" "^2.0.0" @@ -24464,7 +24507,7 @@ unist-util-generated@^1.0.0, unist-util-generated@^1.1.0: unist-util-generated@^2.0.0: version "2.0.0" - resolved "https://registry.npmjs.org/unist-util-generated/-/unist-util-generated-2.0.0.tgz#86fafb77eb6ce9bfa6b663c3f5ad4f8e56a60113" + resolved "https://registry.yarnpkg.com/unist-util-generated/-/unist-util-generated-2.0.0.tgz#86fafb77eb6ce9bfa6b663c3f5ad4f8e56a60113" integrity sha512-TiWE6DVtVe7Ye2QxOVW9kqybs6cZexNwTwSMVgkfjEReqy/xwGpAXb99OxktoWwmL+Z+Epb0Dn8/GNDYP1wnUw== unist-util-inspect@^5.0.0: @@ -24490,7 +24533,7 @@ unist-util-is@^4.0.0: unist-util-is@^5.0.0: version "5.1.1" - resolved "https://registry.npmjs.org/unist-util-is/-/unist-util-is-5.1.1.tgz#e8aece0b102fa9bc097b0fef8f870c496d4a6236" + resolved "https://registry.yarnpkg.com/unist-util-is/-/unist-util-is-5.1.1.tgz#e8aece0b102fa9bc097b0fef8f870c496d4a6236" integrity sha512-F5CZ68eYzuSvJjGhCLPL3cYx45IxkqXSetCcRgUXtbcm50X2L9oOWQlfUfDdAf+6Pd27YDblBfdtmsThXmwpbQ== unist-util-map@^2.0.1: @@ -24510,7 +24553,7 @@ unist-util-modify-children@^1.0.0, unist-util-modify-children@^1.1.1: unist-util-position-from-estree@^1.0.0, unist-util-position-from-estree@^1.1.0: version "1.1.1" - resolved "https://registry.npmjs.org/unist-util-position-from-estree/-/unist-util-position-from-estree-1.1.1.tgz#96f4d543dfb0428edc01ebb928570b602d280c4c" + resolved "https://registry.yarnpkg.com/unist-util-position-from-estree/-/unist-util-position-from-estree-1.1.1.tgz#96f4d543dfb0428edc01ebb928570b602d280c4c" integrity sha512-xtoY50b5+7IH8tFbkw64gisG9tMSpxDjhX9TmaJJae/XuxQ9R/Kc8Nv1eOsf43Gt4KV/LkriMy9mptDr7XLcaw== dependencies: "@types/unist" "^2.0.0" @@ -24522,7 +24565,7 @@ unist-util-position@^3.0.0, unist-util-position@^3.1.0: unist-util-position@^4.0.0: version "4.0.3" - resolved "https://registry.npmjs.org/unist-util-position/-/unist-util-position-4.0.3.tgz#5290547b014f6222dff95c48d5c3c13a88fadd07" + resolved "https://registry.yarnpkg.com/unist-util-position/-/unist-util-position-4.0.3.tgz#5290547b014f6222dff95c48d5c3c13a88fadd07" integrity sha512-p/5EMGIa1qwbXjA+QgcBXaPWjSnZfQ2Sc3yBEEfgPwsEmJd8Qh+DSk3LGnmOM4S1bY2C0AjmMnB8RuEYxpPwXQ== dependencies: "@types/unist" "^2.0.0" @@ -24550,7 +24593,7 @@ unist-util-remove-position@^3.0.0: unist-util-remove-position@^4.0.0: version "4.0.1" - resolved "https://registry.npmjs.org/unist-util-remove-position/-/unist-util-remove-position-4.0.1.tgz#d5b46a7304ac114c8d91990ece085ca7c2c135c8" + resolved "https://registry.yarnpkg.com/unist-util-remove-position/-/unist-util-remove-position-4.0.1.tgz#d5b46a7304ac114c8d91990ece085ca7c2c135c8" integrity sha512-0yDkppiIhDlPrfHELgB+NLQD5mfjup3a8UYclHruTJWmY74je8g+CIFr79x5f6AkmzSwlvKLbs63hC0meOMowQ== dependencies: "@types/unist" "^2.0.0" @@ -24614,16 +24657,16 @@ unist-util-visit-parents@^3.0.0, unist-util-visit-parents@^3.1.1: unist-util-visit-parents@^4.0.0: version "4.1.1" - resolved "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-4.1.1.tgz#e83559a4ad7e6048a46b1bdb22614f2f3f4724f2" + resolved "https://registry.yarnpkg.com/unist-util-visit-parents/-/unist-util-visit-parents-4.1.1.tgz#e83559a4ad7e6048a46b1bdb22614f2f3f4724f2" integrity sha512-1xAFJXAKpnnJl8G7K5KgU7FY55y3GcLIXqkzUj5QF/QVP7biUm0K0O2oqVkYsdjzJKifYeWn9+o6piAK2hGSHw== dependencies: "@types/unist" "^2.0.0" unist-util-is "^5.0.0" -unist-util-visit-parents@^5.0.0: - version "5.1.0" - resolved "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.0.tgz#44bbc5d25f2411e7dfc5cecff12de43296aa8521" - integrity sha512-y+QVLcY5eR/YVpqDsLf/xh9R3Q2Y4HxkZTp7ViLDU6WtJCEcPmRzW1gpdWDCDIqIlhuPDXOgttqPlykrHYDekg== +unist-util-visit-parents@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz#868f353e6fce6bf8fa875b251b0f4fec3be709bb" + integrity sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw== dependencies: "@types/unist" "^2.0.0" unist-util-is "^5.0.0" @@ -24646,7 +24689,7 @@ unist-util-visit@^2.0.0, unist-util-visit@^2.0.3: unist-util-visit@^3.0.0: version "3.1.0" - resolved "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-3.1.0.tgz#9420d285e1aee938c7d9acbafc8e160186dbaf7b" + resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-3.1.0.tgz#9420d285e1aee938c7d9acbafc8e160186dbaf7b" integrity sha512-Szoh+R/Ll68QWAyQyZZpQzZQm2UPbxibDvaY8Xc9SUtYgPsDzx5AWSk++UUt2hJuow8mvwR+rG+LQLw+KsuAKA== dependencies: "@types/unist" "^2.0.0" @@ -24654,13 +24697,13 @@ unist-util-visit@^3.0.0: unist-util-visit-parents "^4.0.0" unist-util-visit@^4.0.0, unist-util-visit@^4.1.0: - version "4.1.0" - resolved "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.0.tgz#f41e407a9e94da31594e6b1c9811c51ab0b3d8f5" - integrity sha512-n7lyhFKJfVZ9MnKtqbsqkQEk5P1KShj0+//V7mAcoI6bpbUjh3C/OG8HVD+pBihfh6Ovl01m8dkcv9HNqYajmQ== + version "4.1.1" + resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-4.1.1.tgz#1c4842d70bd3df6cc545276f5164f933390a9aad" + integrity sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg== dependencies: "@types/unist" "^2.0.0" unist-util-is "^5.0.0" - unist-util-visit-parents "^5.0.0" + unist-util-visit-parents "^5.1.1" universal-url@^2.0.0: version "2.0.0" @@ -24912,9 +24955,9 @@ uuid@^8.3.2: integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== uvu@^0.5.0: - version "0.5.3" - resolved "https://registry.npmjs.org/uvu/-/uvu-0.5.3.tgz#3d83c5bc1230f153451877bfc7f4aea2392219ae" - integrity sha512-brFwqA3FXzilmtnIyJ+CxdkInkY/i4ErvP7uV0DnUVxQcQ55reuHphorpF+tZoVHK2MniZ/VJzI7zJQoc9T9Yw== + version "0.5.6" + resolved "https://registry.yarnpkg.com/uvu/-/uvu-0.5.6.tgz#2754ca20bcb0bb59b64e9985e84d2e81058502df" + integrity sha512-+g8ENReyr8YsOc6fv/NVJs2vFdHBnBNdfE49rshrTzDWOlUx4Gq7KOS2GD8eqhy2j+Ejq29+SbKH8yjkAqXqoA== dependencies: dequal "^2.0.0" diff "^5.0.0" @@ -25068,7 +25111,7 @@ vfile-location@^3.0.0, vfile-location@^3.1.0: vfile-location@^4.0.0: version "4.0.1" - resolved "https://registry.npmjs.org/vfile-location/-/vfile-location-4.0.1.tgz#06f2b9244a3565bef91f099359486a08b10d3a95" + resolved "https://registry.yarnpkg.com/vfile-location/-/vfile-location-4.0.1.tgz#06f2b9244a3565bef91f099359486a08b10d3a95" integrity sha512-JDxPlTbZrZCQXogGheBHjbRWjESSPEak770XwWPfw5mTc1v1nWGLB/apzZxsx8a0SJVfF8HK8ql8RD308vXRUw== dependencies: "@types/unist" "^2.0.0" @@ -25090,7 +25133,7 @@ vfile-message@^2.0.0: vfile-message@^3.0.0: version "3.1.2" - resolved "https://registry.npmjs.org/vfile-message/-/vfile-message-3.1.2.tgz#a2908f64d9e557315ec9d7ea3a910f658ac05f7d" + resolved "https://registry.yarnpkg.com/vfile-message/-/vfile-message-3.1.2.tgz#a2908f64d9e557315ec9d7ea3a910f658ac05f7d" integrity sha512-QjSNP6Yxzyycd4SVOtmKKyTsSvClqBPJcd00Z0zuPj3hOIjg0rUPG6DbFGPvUKRgYyaIWLPKpuEclcuvb3H8qA== dependencies: "@types/unist" "^2.0.0" @@ -25137,9 +25180,9 @@ vfile@^4.0.0: vfile-message "^2.0.0" vfile@^5.0.0, vfile@^5.3.2: - version "5.3.4" - resolved "https://registry.yarnpkg.com/vfile/-/vfile-5.3.4.tgz#bbb8c96b956693bbf70b2c67fdb5781dff769b93" - integrity sha512-KI+7cnst03KbEyN1+JE504zF5bJBZa+J+CrevLeyIMq0aPU681I2rQ5p4PlnQ6exFtWiUrg26QUdFMnAKR6PIw== + version "5.3.5" + resolved "https://registry.yarnpkg.com/vfile/-/vfile-5.3.5.tgz#ec2e206b1414f561c85b7972bb1eeda8ab47ee61" + integrity sha512-U1ho2ga33eZ8y8pkbQLH54uKqGhFJ6GYIHnnG5AhRpAh3OWjkrRHKa/KogbmQn8We+c0KVV3rTOgR9V/WowbXQ== dependencies: "@types/unist" "^2.0.0" is-buffer "^2.0.0" @@ -26114,5 +26157,5 @@ zwitch@^1.0.0: zwitch@^2.0.0: version "2.0.2" - resolved "https://registry.npmjs.org/zwitch/-/zwitch-2.0.2.tgz#91f8d0e901ffa3d66599756dde7f57b17c95dce1" + resolved "https://registry.yarnpkg.com/zwitch/-/zwitch-2.0.2.tgz#91f8d0e901ffa3d66599756dde7f57b17c95dce1" integrity sha512-JZxotl7SxAJH0j7dN4pxsTV6ZLXoLdGME+PsjkL/DaBrVryK9kTGq06GfKrwcSOqypP+fdXGoCHE36b99fWVoA==