@depup/gatsby 5.16.1-depup.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +22 -0
- package/README.md +142 -0
- package/adapters.js +31 -0
- package/apis.json +73 -0
- package/cache-dir/.eslintrc.json +10 -0
- package/cache-dir/api-runner-browser-plugins.js +14 -0
- package/cache-dir/api-runner-browser.js +52 -0
- package/cache-dir/api-runner-ssr.js +88 -0
- package/cache-dir/api-ssr-docs.js +207 -0
- package/cache-dir/app.js +249 -0
- package/cache-dir/blank.css +0 -0
- package/cache-dir/commonjs/api-runner-browser-plugins.js +17 -0
- package/cache-dir/commonjs/api-runner-browser-plugins.js.map +1 -0
- package/cache-dir/commonjs/api-runner-browser.js +49 -0
- package/cache-dir/commonjs/api-runner-browser.js.map +1 -0
- package/cache-dir/commonjs/api-runner-ssr.js +88 -0
- package/cache-dir/commonjs/api-runner-ssr.js.map +1 -0
- package/cache-dir/commonjs/api-ssr-docs.js +210 -0
- package/cache-dir/commonjs/api-ssr-docs.js.map +1 -0
- package/cache-dir/commonjs/app.js +197 -0
- package/cache-dir/commonjs/app.js.map +1 -0
- package/cache-dir/commonjs/context-utils.js +25 -0
- package/cache-dir/commonjs/context-utils.js.map +1 -0
- package/cache-dir/commonjs/create-content-digest-browser-shim.js +4 -0
- package/cache-dir/commonjs/create-content-digest-browser-shim.js.map +1 -0
- package/cache-dir/commonjs/css-to-object.js +21 -0
- package/cache-dir/commonjs/css-to-object.js.map +1 -0
- package/cache-dir/commonjs/debug-log.js +11 -0
- package/cache-dir/commonjs/debug-log.js.map +1 -0
- package/cache-dir/commonjs/default-html.js +33 -0
- package/cache-dir/commonjs/default-html.js.map +1 -0
- package/cache-dir/commonjs/dev-loader.js +247 -0
- package/cache-dir/commonjs/dev-loader.js.map +1 -0
- package/cache-dir/commonjs/develop-static-entry.js +129 -0
- package/cache-dir/commonjs/develop-static-entry.js.map +1 -0
- package/cache-dir/commonjs/dummy.js +8 -0
- package/cache-dir/commonjs/dummy.js.map +1 -0
- package/cache-dir/commonjs/emitter.js +10 -0
- package/cache-dir/commonjs/emitter.js.map +1 -0
- package/cache-dir/commonjs/ensure-resources.js +107 -0
- package/cache-dir/commonjs/ensure-resources.js.map +1 -0
- package/cache-dir/commonjs/error-overlay-handler.js +35 -0
- package/cache-dir/commonjs/error-overlay-handler.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/accordion.js +80 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/accordion.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/build-error.js +44 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/build-error.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/code-frame.js +38 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/code-frame.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/dev-ssr-error.js +52 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/dev-ssr-error.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/error-boundary.js +31 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/error-boundary.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/getserverdata-error.js +47 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/getserverdata-error.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/graphql-errors.js +77 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/graphql-errors.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/hooks.js +93 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/hooks.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/overlay.js +147 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/overlay.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/runtime-errors.js +110 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/runtime-errors.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/use-id.js +50 -0
- package/cache-dir/commonjs/fast-refresh-overlay/components/use-id.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/focus-trap.js +2879 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/focus-trap.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/keys.js +84 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/keys.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/lock-body.js +48 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/lock-body.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/match.js +44 -0
- package/cache-dir/commonjs/fast-refresh-overlay/helpers/match.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/index.js +182 -0
- package/cache-dir/commonjs/fast-refresh-overlay/index.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/style.js +418 -0
- package/cache-dir/commonjs/fast-refresh-overlay/style.js.map +1 -0
- package/cache-dir/commonjs/fast-refresh-overlay/utils.js +75 -0
- package/cache-dir/commonjs/fast-refresh-overlay/utils.js.map +1 -0
- package/cache-dir/commonjs/find-path.js +145 -0
- package/cache-dir/commonjs/find-path.js.map +1 -0
- package/cache-dir/commonjs/gatsby-browser-entry.js +52 -0
- package/cache-dir/commonjs/gatsby-browser-entry.js.map +1 -0
- package/cache-dir/commonjs/head/components/fire-callback-in-effect.js +18 -0
- package/cache-dir/commonjs/head/components/fire-callback-in-effect.js.map +1 -0
- package/cache-dir/commonjs/head/components/head-components.js +72 -0
- package/cache-dir/commonjs/head/components/head-components.js.map +1 -0
- package/cache-dir/commonjs/head/constants.js +13 -0
- package/cache-dir/commonjs/head/constants.js.map +1 -0
- package/cache-dir/commonjs/head/head-export-handler-for-browser.js +144 -0
- package/cache-dir/commonjs/head/head-export-handler-for-browser.js.map +1 -0
- package/cache-dir/commonjs/head/head-export-handler-for-ssr.js +225 -0
- package/cache-dir/commonjs/head/head-export-handler-for-ssr.js.map +1 -0
- package/cache-dir/commonjs/head/utils.js +264 -0
- package/cache-dir/commonjs/head/utils.js.map +1 -0
- package/cache-dir/commonjs/loader.js +861 -0
- package/cache-dir/commonjs/loader.js.map +1 -0
- package/cache-dir/commonjs/loading-indicator/index.js +25 -0
- package/cache-dir/commonjs/loading-indicator/index.js.map +1 -0
- package/cache-dir/commonjs/loading-indicator/indicator.js +63 -0
- package/cache-dir/commonjs/loading-indicator/indicator.js.map +1 -0
- package/cache-dir/commonjs/loading-indicator/style.js +103 -0
- package/cache-dir/commonjs/loading-indicator/style.js.map +1 -0
- package/cache-dir/commonjs/navigation.js +260 -0
- package/cache-dir/commonjs/navigation.js.map +1 -0
- package/cache-dir/commonjs/normalize-page-path.js +22 -0
- package/cache-dir/commonjs/normalize-page-path.js.map +1 -0
- package/cache-dir/commonjs/page-renderer.js +59 -0
- package/cache-dir/commonjs/page-renderer.js.map +1 -0
- package/cache-dir/commonjs/pages.json +1 -0
- package/cache-dir/commonjs/polyfill-entry.js +7 -0
- package/cache-dir/commonjs/polyfill-entry.js.map +1 -0
- package/cache-dir/commonjs/prefetch.js +67 -0
- package/cache-dir/commonjs/prefetch.js.map +1 -0
- package/cache-dir/commonjs/production-app.js +256 -0
- package/cache-dir/commonjs/production-app.js.map +1 -0
- package/cache-dir/commonjs/public-page-renderer-dev.js +26 -0
- package/cache-dir/commonjs/public-page-renderer-dev.js.map +1 -0
- package/cache-dir/commonjs/public-page-renderer-prod.js +30 -0
- package/cache-dir/commonjs/public-page-renderer-prod.js.map +1 -0
- package/cache-dir/commonjs/public-page-renderer.js +11 -0
- package/cache-dir/commonjs/public-page-renderer.js.map +1 -0
- package/cache-dir/commonjs/query-result-store.js +160 -0
- package/cache-dir/commonjs/query-result-store.js.map +1 -0
- package/cache-dir/commonjs/react-dom-utils.js +34 -0
- package/cache-dir/commonjs/react-dom-utils.js.map +1 -0
- package/cache-dir/commonjs/react-lifecycles-compat.js +4 -0
- package/cache-dir/commonjs/react-lifecycles-compat.js.map +1 -0
- package/cache-dir/commonjs/redirect-utils.js +25 -0
- package/cache-dir/commonjs/redirect-utils.js.map +1 -0
- package/cache-dir/commonjs/redirects.json +1 -0
- package/cache-dir/commonjs/register-service-worker.js +66 -0
- package/cache-dir/commonjs/register-service-worker.js.map +1 -0
- package/cache-dir/commonjs/root.js +105 -0
- package/cache-dir/commonjs/root.js.map +1 -0
- package/cache-dir/commonjs/route-announcer-props.js +24 -0
- package/cache-dir/commonjs/route-announcer-props.js.map +1 -0
- package/cache-dir/commonjs/server-utils/writable-as-promise.js +42 -0
- package/cache-dir/commonjs/server-utils/writable-as-promise.js.map +1 -0
- package/cache-dir/commonjs/shadow-portal.js +36 -0
- package/cache-dir/commonjs/shadow-portal.js.map +1 -0
- package/cache-dir/commonjs/slice/context.js +15 -0
- package/cache-dir/commonjs/slice/context.js.map +1 -0
- package/cache-dir/commonjs/slice/inline-slice.js +34 -0
- package/cache-dir/commonjs/slice/inline-slice.js.map +1 -0
- package/cache-dir/commonjs/slice/server-slice-renderer.js +29 -0
- package/cache-dir/commonjs/slice/server-slice-renderer.js.map +1 -0
- package/cache-dir/commonjs/slice/server-slice.js +54 -0
- package/cache-dir/commonjs/slice/server-slice.js.map +1 -0
- package/cache-dir/commonjs/slice.js +124 -0
- package/cache-dir/commonjs/slice.js.map +1 -0
- package/cache-dir/commonjs/socketIo.js +62 -0
- package/cache-dir/commonjs/socketIo.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/child_process.js +8 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/child_process.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/fs.js +7 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/fs.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/http.js +9 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/http.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/http2.js +7 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/http2.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/https.js +9 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/https.js.map +1 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/tracking-unsafe-module-wrapper.js +55 -0
- package/cache-dir/commonjs/ssr-builtin-trackers/tracking-unsafe-module-wrapper.js.map +1 -0
- package/cache-dir/commonjs/ssr-develop-static-entry.js +366 -0
- package/cache-dir/commonjs/ssr-develop-static-entry.js.map +1 -0
- package/cache-dir/commonjs/static-entry.js +544 -0
- package/cache-dir/commonjs/static-entry.js.map +1 -0
- package/cache-dir/commonjs/static-query.js +74 -0
- package/cache-dir/commonjs/static-query.js.map +1 -0
- package/cache-dir/commonjs/strip-prefix.js +22 -0
- package/cache-dir/commonjs/strip-prefix.js.map +1 -0
- package/cache-dir/context-utils.js +29 -0
- package/cache-dir/create-content-digest-browser-shim.js +1 -0
- package/cache-dir/css-to-object.js +19 -0
- package/cache-dir/debug-log.js +13 -0
- package/cache-dir/default-html.js +36 -0
- package/cache-dir/dev-loader.js +280 -0
- package/cache-dir/develop-static-entry.js +129 -0
- package/cache-dir/dummy.js +2 -0
- package/cache-dir/emitter.js +4 -0
- package/cache-dir/ensure-resources.js +119 -0
- package/cache-dir/error-overlay-handler.js +36 -0
- package/cache-dir/fast-refresh-overlay/components/accordion.js +83 -0
- package/cache-dir/fast-refresh-overlay/components/build-error.js +46 -0
- package/cache-dir/fast-refresh-overlay/components/code-frame.js +38 -0
- package/cache-dir/fast-refresh-overlay/components/dev-ssr-error.js +66 -0
- package/cache-dir/fast-refresh-overlay/components/error-boundary.js +28 -0
- package/cache-dir/fast-refresh-overlay/components/getserverdata-error.js +53 -0
- package/cache-dir/fast-refresh-overlay/components/graphql-errors.js +100 -0
- package/cache-dir/fast-refresh-overlay/components/hooks.js +102 -0
- package/cache-dir/fast-refresh-overlay/components/overlay.js +143 -0
- package/cache-dir/fast-refresh-overlay/components/runtime-errors.js +139 -0
- package/cache-dir/fast-refresh-overlay/components/use-id.js +56 -0
- package/cache-dir/fast-refresh-overlay/helpers/focus-trap.js +3561 -0
- package/cache-dir/fast-refresh-overlay/helpers/keys.js +80 -0
- package/cache-dir/fast-refresh-overlay/helpers/lock-body.js +52 -0
- package/cache-dir/fast-refresh-overlay/helpers/match.js +42 -0
- package/cache-dir/fast-refresh-overlay/index.js +147 -0
- package/cache-dir/fast-refresh-overlay/style.js +413 -0
- package/cache-dir/fast-refresh-overlay/utils.js +81 -0
- package/cache-dir/find-path.js +160 -0
- package/cache-dir/gatsby-browser-entry.js +27 -0
- package/cache-dir/head/components/fire-callback-in-effect.js +12 -0
- package/cache-dir/head/components/head-components.js +86 -0
- package/cache-dir/head/constants.js +15 -0
- package/cache-dir/head/head-export-handler-for-browser.js +170 -0
- package/cache-dir/head/head-export-handler-for-ssr.js +237 -0
- package/cache-dir/head/utils.js +287 -0
- package/cache-dir/loader.js +977 -0
- package/cache-dir/loading-indicator/index.js +19 -0
- package/cache-dir/loading-indicator/indicator.js +65 -0
- package/cache-dir/loading-indicator/style.js +99 -0
- package/cache-dir/navigation.js +257 -0
- package/cache-dir/normalize-page-path.js +17 -0
- package/cache-dir/page-renderer.js +59 -0
- package/cache-dir/page-ssr/index.d.ts +76 -0
- package/cache-dir/pages.json +1 -0
- package/cache-dir/polyfill-entry.js +5 -0
- package/cache-dir/prefetch.js +80 -0
- package/cache-dir/production-app.js +340 -0
- package/cache-dir/public-page-renderer-dev.js +21 -0
- package/cache-dir/public-page-renderer-prod.js +25 -0
- package/cache-dir/public-page-renderer.js +9 -0
- package/cache-dir/query-engine/index.d.ts +31 -0
- package/cache-dir/query-result-store.js +197 -0
- package/cache-dir/react-dom-utils.js +38 -0
- package/cache-dir/react-lifecycles-compat.js +1 -0
- package/cache-dir/redirect-utils.js +22 -0
- package/cache-dir/redirects.json +1 -0
- package/cache-dir/register-service-worker.js +64 -0
- package/cache-dir/root.js +147 -0
- package/cache-dir/route-announcer-props.js +18 -0
- package/cache-dir/server-utils/writable-as-promise.js +41 -0
- package/cache-dir/shadow-portal.js +28 -0
- package/cache-dir/slice/context.js +13 -0
- package/cache-dir/slice/inline-slice.js +34 -0
- package/cache-dir/slice/server-slice-renderer.js +28 -0
- package/cache-dir/slice/server-slice.js +52 -0
- package/cache-dir/slice.js +158 -0
- package/cache-dir/socketIo.js +58 -0
- package/cache-dir/ssr-builtin-trackers/child_process.js +4 -0
- package/cache-dir/ssr-builtin-trackers/fs.js +3 -0
- package/cache-dir/ssr-builtin-trackers/http.js +3 -0
- package/cache-dir/ssr-builtin-trackers/http2.js +3 -0
- package/cache-dir/ssr-builtin-trackers/https.js +3 -0
- package/cache-dir/ssr-builtin-trackers/tracking-unsafe-module-wrapper.js +64 -0
- package/cache-dir/ssr-develop-static-entry.js +428 -0
- package/cache-dir/static-entry.js +594 -0
- package/cache-dir/static-query.js +91 -0
- package/cache-dir/strip-prefix.js +20 -0
- package/changes.json +454 -0
- package/cli.js +3 -0
- package/dist/bin/gatsby.js +5 -0
- package/dist/bin/gatsby.js.map +1 -0
- package/dist/bootstrap/__mocks__/get-config/ts/gatsby-config.d.ts +3 -0
- package/dist/bootstrap/__mocks__/resolve-module-exports.d.ts +1 -0
- package/dist/bootstrap/create-graphql-runner.d.ts +10 -0
- package/dist/bootstrap/create-graphql-runner.js +71 -0
- package/dist/bootstrap/create-graphql-runner.js.map +1 -0
- package/dist/bootstrap/get-config-file.d.ts +4 -0
- package/dist/bootstrap/get-config-file.js +152 -0
- package/dist/bootstrap/get-config-file.js.map +1 -0
- package/dist/bootstrap/index.d.ts +12 -0
- package/dist/bootstrap/index.js +56 -0
- package/dist/bootstrap/index.js.map +1 -0
- package/dist/bootstrap/load-config/index.d.ts +7 -0
- package/dist/bootstrap/load-config/index.js +73 -0
- package/dist/bootstrap/load-config/index.js.map +1 -0
- package/dist/bootstrap/load-plugins/index.d.ts +3 -0
- package/dist/bootstrap/load-plugins/index.js +79 -0
- package/dist/bootstrap/load-plugins/index.js.map +1 -0
- package/dist/bootstrap/load-plugins/load-internal-plugins.d.ts +2 -0
- package/dist/bootstrap/load-plugins/load-internal-plugins.js +105 -0
- package/dist/bootstrap/load-plugins/load-internal-plugins.js.map +1 -0
- package/dist/bootstrap/load-plugins/process-plugin.d.ts +2 -0
- package/dist/bootstrap/load-plugins/process-plugin.js +81 -0
- package/dist/bootstrap/load-plugins/process-plugin.js.map +1 -0
- package/dist/bootstrap/load-plugins/resolve-plugin.d.ts +13 -0
- package/dist/bootstrap/load-plugins/resolve-plugin.js +75 -0
- package/dist/bootstrap/load-plugins/resolve-plugin.js.map +1 -0
- package/dist/bootstrap/load-plugins/types.d.ts +48 -0
- package/dist/bootstrap/load-plugins/types.js +4 -0
- package/dist/bootstrap/load-plugins/types.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/check-local-plugin.d.ts +8 -0
- package/dist/bootstrap/load-plugins/utils/check-local-plugin.js +38 -0
- package/dist/bootstrap/load-plugins/utils/check-local-plugin.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/create-hash.d.ts +1 -0
- package/dist/bootstrap/load-plugins/utils/create-hash.js +20 -0
- package/dist/bootstrap/load-plugins/utils/create-hash.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/create-id.d.ts +10 -0
- package/dist/bootstrap/load-plugins/utils/create-id.js +16 -0
- package/dist/bootstrap/load-plugins/utils/create-id.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/flatten-plugins.d.ts +2 -0
- package/dist/bootstrap/load-plugins/utils/flatten-plugins.js +41 -0
- package/dist/bootstrap/load-plugins/utils/flatten-plugins.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/get-api.d.ts +12 -0
- package/dist/bootstrap/load-plugins/utils/get-api.js +12 -0
- package/dist/bootstrap/load-plugins/utils/get-api.js.map +1 -0
- package/dist/bootstrap/load-plugins/utils/normalize.d.ts +5 -0
- package/dist/bootstrap/load-plugins/utils/normalize.js +33 -0
- package/dist/bootstrap/load-plugins/utils/normalize.js.map +1 -0
- package/dist/bootstrap/load-plugins/validate.d.ts +41 -0
- package/dist/bootstrap/load-plugins/validate.js +369 -0
- package/dist/bootstrap/load-plugins/validate.js.map +1 -0
- package/dist/bootstrap/load-themes/index.d.ts +17 -0
- package/dist/bootstrap/load-themes/index.js +186 -0
- package/dist/bootstrap/load-themes/index.js.map +1 -0
- package/dist/bootstrap/log-line-function.d.ts +0 -0
- package/dist/bootstrap/log-line-function.js +19 -0
- package/dist/bootstrap/log-line-function.js.map +1 -0
- package/dist/bootstrap/prefer-default.d.ts +1 -0
- package/dist/bootstrap/prefer-default.js +7 -0
- package/dist/bootstrap/prefer-default.js.map +1 -0
- package/dist/bootstrap/redirects-writer.d.ts +2 -0
- package/dist/bootstrap/redirects-writer.js +59 -0
- package/dist/bootstrap/redirects-writer.js.map +1 -0
- package/dist/bootstrap/remove-stale-jobs.d.ts +2 -0
- package/dist/bootstrap/remove-stale-jobs.js +31 -0
- package/dist/bootstrap/remove-stale-jobs.js.map +1 -0
- package/dist/bootstrap/requires-writer.d.ts +11 -0
- package/dist/bootstrap/requires-writer.js +260 -0
- package/dist/bootstrap/requires-writer.js.map +1 -0
- package/dist/bootstrap/resolve-js-file-path.d.ts +14 -0
- package/dist/bootstrap/resolve-js-file-path.js +58 -0
- package/dist/bootstrap/resolve-js-file-path.js.map +1 -0
- package/dist/bootstrap/resolve-module-exports.d.ts +20 -0
- package/dist/bootstrap/resolve-module-exports.js +188 -0
- package/dist/bootstrap/resolve-module-exports.js.map +1 -0
- package/dist/bootstrap/schema-hot-reloader.d.ts +3 -0
- package/dist/bootstrap/schema-hot-reloader.js +60 -0
- package/dist/bootstrap/schema-hot-reloader.js.map +1 -0
- package/dist/cache/cache-fs.d.ts +1 -0
- package/dist/cache/cache-fs.js +270 -0
- package/dist/cache/cache-fs.js.map +1 -0
- package/dist/cache/json-file-store.d.ts +8 -0
- package/dist/cache/json-file-store.js +144 -0
- package/dist/cache/json-file-store.js.map +1 -0
- package/dist/cache/wrap-callback.d.ts +0 -0
- package/dist/cache/wrap-callback.js +49 -0
- package/dist/cache/wrap-callback.js.map +1 -0
- package/dist/commands/build-html.d.ts +69 -0
- package/dist/commands/build-html.js +652 -0
- package/dist/commands/build-html.js.map +1 -0
- package/dist/commands/build-javascript.d.ts +4 -0
- package/dist/commands/build-javascript.js +18 -0
- package/dist/commands/build-javascript.js.map +1 -0
- package/dist/commands/build-utils.d.ts +8 -0
- package/dist/commands/build-utils.js +186 -0
- package/dist/commands/build-utils.js.map +1 -0
- package/dist/commands/build.d.ts +1 -0
- package/dist/commands/build.js +505 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/clean.d.ts +1 -0
- package/dist/commands/clean.js +29 -0
- package/dist/commands/clean.js.map +1 -0
- package/dist/commands/develop-process.d.ts +1 -0
- package/dist/commands/develop-process.js +120 -0
- package/dist/commands/develop-process.js.map +1 -0
- package/dist/commands/develop-static.d.ts +3 -0
- package/dist/commands/develop-static.js +22 -0
- package/dist/commands/develop-static.js.map +1 -0
- package/dist/commands/develop.d.ts +2 -0
- package/dist/commands/develop.js +273 -0
- package/dist/commands/develop.js.map +1 -0
- package/dist/commands/feedback.d.ts +1 -0
- package/dist/commands/feedback.js +17 -0
- package/dist/commands/feedback.js.map +1 -0
- package/dist/commands/repl.d.ts +1 -0
- package/dist/commands/repl.js +58 -0
- package/dist/commands/repl.js.map +1 -0
- package/dist/commands/serve.d.ts +1 -0
- package/dist/commands/serve.js +282 -0
- package/dist/commands/serve.js.map +1 -0
- package/dist/commands/types.d.ts +54 -0
- package/dist/commands/types.js +23 -0
- package/dist/commands/types.js.map +1 -0
- package/dist/constants.d.ts +1 -0
- package/dist/constants.js +7 -0
- package/dist/constants.js.map +1 -0
- package/dist/datastore/common/iterable.d.ts +51 -0
- package/dist/datastore/common/iterable.js +217 -0
- package/dist/datastore/common/iterable.js.map +1 -0
- package/dist/datastore/common/query.d.ts +69 -0
- package/dist/datastore/common/query.js +219 -0
- package/dist/datastore/common/query.js.map +1 -0
- package/dist/datastore/datastore.d.ts +2 -0
- package/dist/datastore/datastore.js +23 -0
- package/dist/datastore/datastore.js.map +1 -0
- package/dist/datastore/in-memory/in-memory-datastore.d.ts +2 -0
- package/dist/datastore/in-memory/in-memory-datastore.js +75 -0
- package/dist/datastore/in-memory/in-memory-datastore.js.map +1 -0
- package/dist/datastore/in-memory/indexing.d.ts +80 -0
- package/dist/datastore/in-memory/indexing.js +994 -0
- package/dist/datastore/in-memory/indexing.js.map +1 -0
- package/dist/datastore/in-memory/run-fast-filters.d.ts +27 -0
- package/dist/datastore/in-memory/run-fast-filters.js +276 -0
- package/dist/datastore/in-memory/run-fast-filters.js.map +1 -0
- package/dist/datastore/index.d.ts +20 -0
- package/dist/datastore/index.js +34 -0
- package/dist/datastore/index.js.map +1 -0
- package/dist/datastore/lmdb/lmdb-datastore.d.ts +14 -0
- package/dist/datastore/lmdb/lmdb-datastore.js +261 -0
- package/dist/datastore/lmdb/lmdb-datastore.js.map +1 -0
- package/dist/datastore/lmdb/query/common.d.ts +23 -0
- package/dist/datastore/lmdb/query/common.js +127 -0
- package/dist/datastore/lmdb/query/common.js.map +1 -0
- package/dist/datastore/lmdb/query/create-index.d.ts +25 -0
- package/dist/datastore/lmdb/query/create-index.js +239 -0
- package/dist/datastore/lmdb/query/create-index.js.map +1 -0
- package/dist/datastore/lmdb/query/filter-using-index.d.ts +43 -0
- package/dist/datastore/lmdb/query/filter-using-index.js +577 -0
- package/dist/datastore/lmdb/query/filter-using-index.js.map +1 -0
- package/dist/datastore/lmdb/query/run-query.d.ts +9 -0
- package/dist/datastore/lmdb/query/run-query.js +285 -0
- package/dist/datastore/lmdb/query/run-query.js.map +1 -0
- package/dist/datastore/lmdb/query/suggest-index.d.ts +15 -0
- package/dist/datastore/lmdb/query/suggest-index.js +93 -0
- package/dist/datastore/lmdb/query/suggest-index.js.map +1 -0
- package/dist/datastore/lmdb/updates/nodes-by-type.d.ts +3 -0
- package/dist/datastore/lmdb/updates/nodes-by-type.js +21 -0
- package/dist/datastore/lmdb/updates/nodes-by-type.js.map +1 -0
- package/dist/datastore/lmdb/updates/nodes.d.ts +5 -0
- package/dist/datastore/lmdb/updates/nodes.js +33 -0
- package/dist/datastore/lmdb/updates/nodes.js.map +1 -0
- package/dist/datastore/types.d.ts +47 -0
- package/dist/datastore/types.js +4 -0
- package/dist/datastore/types.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/gatsby-node.js +42 -0
- package/dist/internal-plugins/bundle-optimisations/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/index.js +3 -0
- package/dist/internal-plugins/bundle-optimisations/index.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/package.json +10 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/fetch.js +4 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/fetch.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/no-op.js +3 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/no-op.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/object-assign.js +4 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/object-assign.js.map +1 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/whatwg-fetch.js +6 -0
- package/dist/internal-plugins/bundle-optimisations/polyfills/whatwg-fetch.js.map +1 -0
- package/dist/internal-plugins/dev-404-page/gatsby-node.js +30 -0
- package/dist/internal-plugins/dev-404-page/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/dev-404-page/index.js +3 -0
- package/dist/internal-plugins/dev-404-page/index.js.map +1 -0
- package/dist/internal-plugins/dev-404-page/package.json +11 -0
- package/dist/internal-plugins/dev-404-page/raw_dev-404-page.js +262 -0
- package/dist/internal-plugins/functions/api-function-webpack-loader.d.ts +3 -0
- package/dist/internal-plugins/functions/api-function-webpack-loader.js +74 -0
- package/dist/internal-plugins/functions/api-function-webpack-loader.js.map +1 -0
- package/dist/internal-plugins/functions/config.d.ts +20 -0
- package/dist/internal-plugins/functions/config.js +96 -0
- package/dist/internal-plugins/functions/config.js.map +1 -0
- package/dist/internal-plugins/functions/gatsby-node.d.ts +3 -0
- package/dist/internal-plugins/functions/gatsby-node.js +452 -0
- package/dist/internal-plugins/functions/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/functions/index.js +3 -0
- package/dist/internal-plugins/functions/index.js.map +1 -0
- package/dist/internal-plugins/functions/middleware.d.ts +11 -0
- package/dist/internal-plugins/functions/middleware.js +160 -0
- package/dist/internal-plugins/functions/middleware.js.map +1 -0
- package/dist/internal-plugins/functions/package.json +11 -0
- package/dist/internal-plugins/internal-data-bridge/gatsby-node.js +191 -0
- package/dist/internal-plugins/internal-data-bridge/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/internal-data-bridge/index.js +3 -0
- package/dist/internal-plugins/internal-data-bridge/index.js.map +1 -0
- package/dist/internal-plugins/internal-data-bridge/package.json +11 -0
- package/dist/internal-plugins/load-babel-config/gatsby-node.js +37 -0
- package/dist/internal-plugins/load-babel-config/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/load-babel-config/index.js +3 -0
- package/dist/internal-plugins/load-babel-config/index.js.map +1 -0
- package/dist/internal-plugins/load-babel-config/package.json +11 -0
- package/dist/internal-plugins/partytown/gatsby-browser.js +23 -0
- package/dist/internal-plugins/partytown/gatsby-browser.js.map +1 -0
- package/dist/internal-plugins/partytown/gatsby-node.d.ts +2 -0
- package/dist/internal-plugins/partytown/gatsby-node.js +60 -0
- package/dist/internal-plugins/partytown/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/partytown/gatsby-ssr.js +39 -0
- package/dist/internal-plugins/partytown/gatsby-ssr.js.map +1 -0
- package/dist/internal-plugins/partytown/index.js +3 -0
- package/dist/internal-plugins/partytown/index.js.map +1 -0
- package/dist/internal-plugins/partytown/package.json +12 -0
- package/dist/internal-plugins/partytown/proxy.d.ts +3 -0
- package/dist/internal-plugins/partytown/proxy.js +26 -0
- package/dist/internal-plugins/partytown/proxy.js.map +1 -0
- package/dist/internal-plugins/partytown/utils/get-forwards.d.ts +2 -0
- package/dist/internal-plugins/partytown/utils/get-forwards.js +8 -0
- package/dist/internal-plugins/partytown/utils/get-forwards.js.map +1 -0
- package/dist/internal-plugins/partytown/utils/inject-partytown-snippet.d.ts +2 -0
- package/dist/internal-plugins/partytown/utils/inject-partytown-snippet.js +28 -0
- package/dist/internal-plugins/partytown/utils/inject-partytown-snippet.js.map +1 -0
- package/dist/internal-plugins/prod-404-500/gatsby-node.js +50 -0
- package/dist/internal-plugins/prod-404-500/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/prod-404-500/index.js +3 -0
- package/dist/internal-plugins/prod-404-500/index.js.map +1 -0
- package/dist/internal-plugins/prod-404-500/package.json +11 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/create-page.js +31 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/create-page.js.map +1 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/gatsby-node.js +31 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/index.js +273 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/index.js.map +1 -0
- package/dist/internal-plugins/webpack-theme-component-shadowing/package.json +11 -0
- package/dist/internal.d.ts +5 -0
- package/dist/internal.js +34 -0
- package/dist/internal.js.map +1 -0
- package/dist/joi-schemas/joi.d.ts +5 -0
- package/dist/joi-schemas/joi.js +122 -0
- package/dist/joi-schemas/joi.js.map +1 -0
- package/dist/query/error-parser.d.ts +19 -0
- package/dist/query/error-parser.js +163 -0
- package/dist/query/error-parser.js.map +1 -0
- package/dist/query/file-parser.js +584 -0
- package/dist/query/file-parser.js.map +1 -0
- package/dist/query/graphql-errors-codeframe.d.ts +1 -0
- package/dist/query/graphql-errors-codeframe.js +20 -0
- package/dist/query/graphql-errors-codeframe.js.map +1 -0
- package/dist/query/graphql-errors.js +278 -0
- package/dist/query/graphql-errors.js.map +1 -0
- package/dist/query/graphql-runner.d.ts +39 -0
- package/dist/query/graphql-runner.js +221 -0
- package/dist/query/graphql-runner.js.map +1 -0
- package/dist/query/graphql-span-tracer.d.ts +19 -0
- package/dist/query/graphql-span-tracer.js +63 -0
- package/dist/query/graphql-span-tracer.js.map +1 -0
- package/dist/query/index.d.ts +32 -0
- package/dist/query/index.js +301 -0
- package/dist/query/index.js.map +1 -0
- package/dist/query/query-compiler.js +433 -0
- package/dist/query/query-compiler.js.map +1 -0
- package/dist/query/query-runner.d.ts +13 -0
- package/dist/query/query-runner.js +176 -0
- package/dist/query/query-runner.js.map +1 -0
- package/dist/query/query-watcher.d.ts +17 -0
- package/dist/query/query-watcher.js +250 -0
- package/dist/query/query-watcher.js.map +1 -0
- package/dist/query/transform-document.d.ts +6 -0
- package/dist/query/transform-document.js +131 -0
- package/dist/query/transform-document.js.map +1 -0
- package/dist/query/types.d.ts +35 -0
- package/dist/query/types.js +4 -0
- package/dist/query/types.js.map +1 -0
- package/dist/query/utils.d.ts +4 -0
- package/dist/query/utils.js +20 -0
- package/dist/query/utils.js.map +1 -0
- package/dist/redux/actions/add-page-dependency.d.ts +7 -0
- package/dist/redux/actions/add-page-dependency.js +52 -0
- package/dist/redux/actions/add-page-dependency.js.map +1 -0
- package/dist/redux/actions/index.d.ts +16 -0
- package/dist/redux/actions/index.js +21 -0
- package/dist/redux/actions/index.js.map +1 -0
- package/dist/redux/actions/internal.d.ts +124 -0
- package/dist/redux/actions/internal.js +394 -0
- package/dist/redux/actions/internal.js.map +1 -0
- package/dist/redux/actions/public.js +1354 -0
- package/dist/redux/actions/public.js.map +1 -0
- package/dist/redux/actions/restricted.d.ts +332 -0
- package/dist/redux/actions/restricted.js +521 -0
- package/dist/redux/actions/restricted.js.map +1 -0
- package/dist/redux/index.d.ts +20 -0
- package/dist/redux/index.js +125 -0
- package/dist/redux/index.js.map +1 -0
- package/dist/redux/persist.d.ts +5 -0
- package/dist/redux/persist.js +191 -0
- package/dist/redux/persist.js.map +1 -0
- package/dist/redux/plugin-runner.d.ts +1 -0
- package/dist/redux/plugin-runner.js +45 -0
- package/dist/redux/plugin-runner.js.map +1 -0
- package/dist/redux/reducers/adapter.d.ts +6 -0
- package/dist/redux/reducers/adapter.js +22 -0
- package/dist/redux/reducers/adapter.js.map +1 -0
- package/dist/redux/reducers/babelrc.d.ts +9 -0
- package/dist/redux/reducers/babelrc.js +104 -0
- package/dist/redux/reducers/babelrc.js.map +1 -0
- package/dist/redux/reducers/components-using-slices.d.ts +2 -0
- package/dist/redux/reducers/components-using-slices.js +15 -0
- package/dist/redux/reducers/components-using-slices.js.map +1 -0
- package/dist/redux/reducers/components.d.ts +2 -0
- package/dist/redux/reducers/components.js +104 -0
- package/dist/redux/reducers/components.js.map +1 -0
- package/dist/redux/reducers/config.d.ts +2 -0
- package/dist/redux/reducers/config.js +16 -0
- package/dist/redux/reducers/config.js.map +1 -0
- package/dist/redux/reducers/definitions.d.ts +2 -0
- package/dist/redux/reducers/definitions.js +14 -0
- package/dist/redux/reducers/definitions.js.map +1 -0
- package/dist/redux/reducers/flattened-plugins.d.ts +17 -0
- package/dist/redux/reducers/flattened-plugins.js +14 -0
- package/dist/redux/reducers/flattened-plugins.js.map +1 -0
- package/dist/redux/reducers/functions.d.ts +2 -0
- package/dist/redux/reducers/functions.js +14 -0
- package/dist/redux/reducers/functions.js.map +1 -0
- package/dist/redux/reducers/html.d.ts +25 -0
- package/dist/redux/reducers/html.js +384 -0
- package/dist/redux/reducers/html.js.map +1 -0
- package/dist/redux/reducers/index.d.ts +45 -0
- package/dist/redux/reducers/index.js +86 -0
- package/dist/redux/reducers/index.js.map +1 -0
- package/dist/redux/reducers/inference-metadata.d.ts +7 -0
- package/dist/redux/reducers/inference-metadata.js +174 -0
- package/dist/redux/reducers/inference-metadata.js.map +1 -0
- package/dist/redux/reducers/jobs.d.ts +5 -0
- package/dist/redux/reducers/jobs.js +65 -0
- package/dist/redux/reducers/jobs.js.map +1 -0
- package/dist/redux/reducers/jobsv2.d.ts +6 -0
- package/dist/redux/reducers/jobsv2.js +88 -0
- package/dist/redux/reducers/jobsv2.js.map +1 -0
- package/dist/redux/reducers/last-action.d.ts +2 -0
- package/dist/redux/reducers/last-action.js +7 -0
- package/dist/redux/reducers/last-action.js.map +1 -0
- package/dist/redux/reducers/node-manifest.d.ts +2 -0
- package/dist/redux/reducers/node-manifest.js +58 -0
- package/dist/redux/reducers/node-manifest.js.map +1 -0
- package/dist/redux/reducers/nodes-by-type.d.ts +2 -0
- package/dist/redux/reducers/nodes-by-type.js +53 -0
- package/dist/redux/reducers/nodes-by-type.js.map +1 -0
- package/dist/redux/reducers/nodes-touched.d.ts +3 -0
- package/dist/redux/reducers/nodes-touched.js +18 -0
- package/dist/redux/reducers/nodes-touched.js.map +1 -0
- package/dist/redux/reducers/nodes.d.ts +2 -0
- package/dist/redux/reducers/nodes.js +30 -0
- package/dist/redux/reducers/nodes.js.map +1 -0
- package/dist/redux/reducers/page-data-stats.d.ts +2 -0
- package/dist/redux/reducers/page-data-stats.js +15 -0
- package/dist/redux/reducers/page-data-stats.js.map +1 -0
- package/dist/redux/reducers/pages.d.ts +2 -0
- package/dist/redux/reducers/pages.js +43 -0
- package/dist/redux/reducers/pages.js.map +1 -0
- package/dist/redux/reducers/pending-page-data-writes.d.ts +5 -0
- package/dist/redux/reducers/pending-page-data-writes.js +66 -0
- package/dist/redux/reducers/pending-page-data-writes.js.map +1 -0
- package/dist/redux/reducers/program.d.ts +2 -0
- package/dist/redux/reducers/program.js +62 -0
- package/dist/redux/reducers/program.js.map +1 -0
- package/dist/redux/reducers/queries.d.ts +26 -0
- package/dist/redux/reducers/queries.js +403 -0
- package/dist/redux/reducers/queries.js.map +1 -0
- package/dist/redux/reducers/redirects.d.ts +2 -0
- package/dist/redux/reducers/redirects.js +39 -0
- package/dist/redux/reducers/redirects.js.map +1 -0
- package/dist/redux/reducers/remote-file-allowed-urls.d.ts +2 -0
- package/dist/redux/reducers/remote-file-allowed-urls.js +19 -0
- package/dist/redux/reducers/remote-file-allowed-urls.js.map +1 -0
- package/dist/redux/reducers/resolved-nodes.d.ts +2 -0
- package/dist/redux/reducers/resolved-nodes.js +45 -0
- package/dist/redux/reducers/resolved-nodes.js.map +1 -0
- package/dist/redux/reducers/schema-customization.d.ts +23 -0
- package/dist/redux/reducers/schema-customization.js +103 -0
- package/dist/redux/reducers/schema-customization.js.map +1 -0
- package/dist/redux/reducers/schema.d.ts +3 -0
- package/dist/redux/reducers/schema.js +17 -0
- package/dist/redux/reducers/schema.js.map +1 -0
- package/dist/redux/reducers/set-request-headers.d.ts +7 -0
- package/dist/redux/reducers/set-request-headers.js +24 -0
- package/dist/redux/reducers/set-request-headers.js.map +1 -0
- package/dist/redux/reducers/slices-by-template.d.ts +2 -0
- package/dist/redux/reducers/slices-by-template.js +16 -0
- package/dist/redux/reducers/slices-by-template.js.map +1 -0
- package/dist/redux/reducers/slices.d.ts +2 -0
- package/dist/redux/reducers/slices.js +22 -0
- package/dist/redux/reducers/slices.js.map +1 -0
- package/dist/redux/reducers/stateful-source-plugins.d.ts +5 -0
- package/dist/redux/reducers/stateful-source-plugins.js +20 -0
- package/dist/redux/reducers/stateful-source-plugins.js.map +1 -0
- package/dist/redux/reducers/static-queries-by-template.d.ts +2 -0
- package/dist/redux/reducers/static-queries-by-template.js +19 -0
- package/dist/redux/reducers/static-queries-by-template.js.map +1 -0
- package/dist/redux/reducers/static-query-components.d.ts +2 -0
- package/dist/redux/reducers/static-query-components.js +18 -0
- package/dist/redux/reducers/static-query-components.js.map +1 -0
- package/dist/redux/reducers/status.d.ts +7 -0
- package/dist/redux/reducers/status.js +57 -0
- package/dist/redux/reducers/status.js.map +1 -0
- package/dist/redux/reducers/telemetry.d.ts +2 -0
- package/dist/redux/reducers/telemetry.js +46 -0
- package/dist/redux/reducers/telemetry.js.map +1 -0
- package/dist/redux/reducers/type-owners.d.ts +5 -0
- package/dist/redux/reducers/type-owners.js +102 -0
- package/dist/redux/reducers/type-owners.js.map +1 -0
- package/dist/redux/reducers/visited-page.d.ts +2 -0
- package/dist/redux/reducers/visited-page.js +31 -0
- package/dist/redux/reducers/visited-page.js.map +1 -0
- package/dist/redux/reducers/webpack-compilation-hash.d.ts +2 -0
- package/dist/redux/reducers/webpack-compilation-hash.js +14 -0
- package/dist/redux/reducers/webpack-compilation-hash.js.map +1 -0
- package/dist/redux/reducers/webpack.d.ts +2 -0
- package/dist/redux/reducers/webpack.js +27 -0
- package/dist/redux/reducers/webpack.js.map +1 -0
- package/dist/redux/save-state.js +19 -0
- package/dist/redux/save-state.js.map +1 -0
- package/dist/redux/types.d.ts +1337 -0
- package/dist/redux/types.js +326 -0
- package/dist/redux/types.js.map +1 -0
- package/dist/schema/context.d.ts +14 -0
- package/dist/schema/context.js +38 -0
- package/dist/schema/context.js.map +1 -0
- package/dist/schema/extensions/index.js +205 -0
- package/dist/schema/extensions/index.js.map +1 -0
- package/dist/schema/graphql-engine/bootstrap.d.ts +2 -0
- package/dist/schema/graphql-engine/bootstrap.js +12 -0
- package/dist/schema/graphql-engine/bootstrap.js.map +1 -0
- package/dist/schema/graphql-engine/bundle-webpack.d.ts +5 -0
- package/dist/schema/graphql-engine/bundle-webpack.js +446 -0
- package/dist/schema/graphql-engine/bundle-webpack.js.map +1 -0
- package/dist/schema/graphql-engine/entry.d.ts +23 -0
- package/dist/schema/graphql-engine/entry.js +204 -0
- package/dist/schema/graphql-engine/entry.js.map +1 -0
- package/dist/schema/graphql-engine/lmdb-bundling-patch.d.ts +1 -0
- package/dist/schema/graphql-engine/lmdb-bundling-patch.js +72 -0
- package/dist/schema/graphql-engine/lmdb-bundling-patch.js.map +1 -0
- package/dist/schema/graphql-engine/platform-and-arch-check.d.ts +0 -0
- package/dist/schema/graphql-engine/platform-and-arch-check.js +6 -0
- package/dist/schema/graphql-engine/platform-and-arch-check.js.map +1 -0
- package/dist/schema/graphql-engine/print-plugins.d.ts +2 -0
- package/dist/schema/graphql-engine/print-plugins.js +145 -0
- package/dist/schema/graphql-engine/print-plugins.js.map +1 -0
- package/dist/schema/graphql-engine/sharp-bundling-patch.d.ts +1 -0
- package/dist/schema/graphql-engine/sharp-bundling-patch.js +8 -0
- package/dist/schema/graphql-engine/sharp-bundling-patch.js.map +1 -0
- package/dist/schema/graphql-engine/shims/gatsby-sharp.js +10 -0
- package/dist/schema/graphql-engine/shims/gatsby-sharp.js.map +1 -0
- package/dist/schema/graphql-engine/shims/no-op-module.js +3 -0
- package/dist/schema/graphql-engine/shims/no-op-module.js.map +1 -0
- package/dist/schema/graphql-engine/shims/ts-node.js +17 -0
- package/dist/schema/graphql-engine/shims/ts-node.js.map +1 -0
- package/dist/schema/graphql-engine/standalone-regenerate.d.ts +2 -0
- package/dist/schema/graphql-engine/standalone-regenerate.js +73 -0
- package/dist/schema/graphql-engine/standalone-regenerate.js.map +1 -0
- package/dist/schema/index.js +189 -0
- package/dist/schema/index.js.map +1 -0
- package/dist/schema/infer/add-inferred-fields.js +413 -0
- package/dist/schema/infer/add-inferred-fields.js.map +1 -0
- package/dist/schema/infer/build-example-data.d.ts +5 -0
- package/dist/schema/infer/build-example-data.js +199 -0
- package/dist/schema/infer/build-example-data.js.map +1 -0
- package/dist/schema/infer/index.js +121 -0
- package/dist/schema/infer/index.js.map +1 -0
- package/dist/schema/infer/inference-metadata.d.ts +72 -0
- package/dist/schema/infer/inference-metadata.js +280 -0
- package/dist/schema/infer/inference-metadata.js.map +1 -0
- package/dist/schema/infer/is-file.d.ts +1 -0
- package/dist/schema/infer/is-file.js +65 -0
- package/dist/schema/infer/is-file.js.map +1 -0
- package/dist/schema/infer/type-conflict-reporter.d.ts +28 -0
- package/dist/schema/infer/type-conflict-reporter.js +104 -0
- package/dist/schema/infer/type-conflict-reporter.js.map +1 -0
- package/dist/schema/node-model.js +784 -0
- package/dist/schema/node-model.js.map +1 -0
- package/dist/schema/print.d.ts +20 -0
- package/dist/schema/print.js +279 -0
- package/dist/schema/print.js.map +1 -0
- package/dist/schema/resolvers.d.ts +40 -0
- package/dist/schema/resolvers.js +569 -0
- package/dist/schema/resolvers.js.map +1 -0
- package/dist/schema/schema-composer.d.ts +3 -0
- package/dist/schema/schema-composer.js +31 -0
- package/dist/schema/schema-composer.js.map +1 -0
- package/dist/schema/schema.js +1295 -0
- package/dist/schema/schema.js.map +1 -0
- package/dist/schema/type-definitions.d.ts +47 -0
- package/dist/schema/type-definitions.js +4 -0
- package/dist/schema/type-definitions.js.map +1 -0
- package/dist/schema/types/built-in-types.d.ts +5 -0
- package/dist/schema/types/built-in-types.js +139 -0
- package/dist/schema/types/built-in-types.js.map +1 -0
- package/dist/schema/types/date.d.ts +37 -0
- package/dist/schema/types/date.js +225 -0
- package/dist/schema/types/date.js.map +1 -0
- package/dist/schema/types/derived-types.d.ts +45 -0
- package/dist/schema/types/derived-types.js +108 -0
- package/dist/schema/types/derived-types.js.map +1 -0
- package/dist/schema/types/filter.d.ts +12 -0
- package/dist/schema/types/filter.js +105 -0
- package/dist/schema/types/filter.js.map +1 -0
- package/dist/schema/types/media.d.ts +2 -0
- package/dist/schema/types/media.js +10 -0
- package/dist/schema/types/media.js.map +1 -0
- package/dist/schema/types/node-interface.d.ts +14 -0
- package/dist/schema/types/node-interface.js +103 -0
- package/dist/schema/types/node-interface.js.map +1 -0
- package/dist/schema/types/pagination.d.ts +16 -0
- package/dist/schema/types/pagination.js +198 -0
- package/dist/schema/types/pagination.js.map +1 -0
- package/dist/schema/types/remote-file-interface.d.ts +3 -0
- package/dist/schema/types/remote-file-interface.js +34 -0
- package/dist/schema/types/remote-file-interface.js.map +1 -0
- package/dist/schema/types/sort.d.ts +24 -0
- package/dist/schema/types/sort.js +178 -0
- package/dist/schema/types/sort.js.map +1 -0
- package/dist/schema/types/type-builders.d.ts +36 -0
- package/dist/schema/types/type-builders.js +61 -0
- package/dist/schema/types/type-builders.js.map +1 -0
- package/dist/schema/types/type-defs.js +86 -0
- package/dist/schema/types/type-defs.js.map +1 -0
- package/dist/schema/types/utils.d.ts +33 -0
- package/dist/schema/types/utils.js +153 -0
- package/dist/schema/types/utils.js.map +1 -0
- package/dist/schema/utils.d.ts +28 -0
- package/dist/schema/utils.js +149 -0
- package/dist/schema/utils.js.map +1 -0
- package/dist/services/build-schema.d.ts +2 -0
- package/dist/services/build-schema.js +24 -0
- package/dist/services/build-schema.js.map +1 -0
- package/dist/services/calculate-dirty-queries.d.ts +5 -0
- package/dist/services/calculate-dirty-queries.js +44 -0
- package/dist/services/calculate-dirty-queries.js.map +1 -0
- package/dist/services/create-pages.d.ts +5 -0
- package/dist/services/create-pages.js +108 -0
- package/dist/services/create-pages.js.map +1 -0
- package/dist/services/customize-schema.d.ts +2 -0
- package/dist/services/customize-schema.js +26 -0
- package/dist/services/customize-schema.js.map +1 -0
- package/dist/services/extract-queries.d.ts +2 -0
- package/dist/services/extract-queries.js +24 -0
- package/dist/services/extract-queries.js.map +1 -0
- package/dist/services/graphql-typegen.d.ts +2 -0
- package/dist/services/graphql-typegen.js +46 -0
- package/dist/services/graphql-typegen.js.map +1 -0
- package/dist/services/index.d.ts +19 -0
- package/dist/services/index.js +68 -0
- package/dist/services/index.js.map +1 -0
- package/dist/services/initialize.d.ts +14 -0
- package/dist/services/initialize.js +519 -0
- package/dist/services/initialize.js.map +1 -0
- package/dist/services/listen-for-mutations.d.ts +2 -0
- package/dist/services/listen-for-mutations.js +59 -0
- package/dist/services/listen-for-mutations.js.map +1 -0
- package/dist/services/listen-to-webpack.d.ts +3 -0
- package/dist/services/listen-to-webpack.js +17 -0
- package/dist/services/listen-to-webpack.js.map +1 -0
- package/dist/services/post-bootstrap.d.ts +2 -0
- package/dist/services/post-bootstrap.js +29 -0
- package/dist/services/post-bootstrap.js.map +1 -0
- package/dist/services/recompile.d.ts +3 -0
- package/dist/services/recompile.js +67 -0
- package/dist/services/recompile.js.map +1 -0
- package/dist/services/run-mutation-batch.d.ts +2 -0
- package/dist/services/run-mutation-batch.js +12 -0
- package/dist/services/run-mutation-batch.js.map +1 -0
- package/dist/services/run-page-queries.d.ts +2 -0
- package/dist/services/run-page-queries.js +38 -0
- package/dist/services/run-page-queries.js.map +1 -0
- package/dist/services/run-slice-queries.d.ts +2 -0
- package/dist/services/run-slice-queries.js +40 -0
- package/dist/services/run-slice-queries.js.map +1 -0
- package/dist/services/run-static-queries.d.ts +2 -0
- package/dist/services/run-static-queries.js +38 -0
- package/dist/services/run-static-queries.js.map +1 -0
- package/dist/services/source-nodes.d.ts +5 -0
- package/dist/services/source-nodes.js +47 -0
- package/dist/services/source-nodes.js.map +1 -0
- package/dist/services/start-webpack-server.d.ts +9 -0
- package/dist/services/start-webpack-server.js +103 -0
- package/dist/services/start-webpack-server.js.map +1 -0
- package/dist/services/types.d.ts +53 -0
- package/dist/services/types.js +4 -0
- package/dist/services/types.js.map +1 -0
- package/dist/services/write-out-redirects.d.ts +2 -0
- package/dist/services/write-out-redirects.js +20 -0
- package/dist/services/write-out-redirects.js.map +1 -0
- package/dist/services/write-out-requires.d.ts +2 -0
- package/dist/services/write-out-requires.js +27 -0
- package/dist/services/write-out-requires.js.map +1 -0
- package/dist/state-machines/data-layer/actions.d.ts +11 -0
- package/dist/state-machines/data-layer/actions.js +38 -0
- package/dist/state-machines/data-layer/actions.js.map +1 -0
- package/dist/state-machines/data-layer/index.d.ts +24 -0
- package/dist/state-machines/data-layer/index.js +152 -0
- package/dist/state-machines/data-layer/index.js.map +1 -0
- package/dist/state-machines/data-layer/services.d.ts +3 -0
- package/dist/state-machines/data-layer/services.js +14 -0
- package/dist/state-machines/data-layer/services.js.map +1 -0
- package/dist/state-machines/data-layer/types.d.ts +27 -0
- package/dist/state-machines/data-layer/types.js +4 -0
- package/dist/state-machines/data-layer/types.js.map +1 -0
- package/dist/state-machines/develop/actions.d.ts +68 -0
- package/dist/state-machines/develop/actions.js +259 -0
- package/dist/state-machines/develop/actions.js.map +1 -0
- package/dist/state-machines/develop/index.d.ts +5 -0
- package/dist/state-machines/develop/index.js +372 -0
- package/dist/state-machines/develop/index.js.map +1 -0
- package/dist/state-machines/develop/services.d.ts +3 -0
- package/dist/state-machines/develop/services.js +22 -0
- package/dist/state-machines/develop/services.js.map +1 -0
- package/dist/state-machines/index.d.ts +7 -0
- package/dist/state-machines/index.js +21 -0
- package/dist/state-machines/index.js.map +1 -0
- package/dist/state-machines/query-running/actions.d.ts +9 -0
- package/dist/state-machines/query-running/actions.js +55 -0
- package/dist/state-machines/query-running/actions.js.map +1 -0
- package/dist/state-machines/query-running/index.d.ts +7 -0
- package/dist/state-machines/query-running/index.js +142 -0
- package/dist/state-machines/query-running/index.js.map +1 -0
- package/dist/state-machines/query-running/services.d.ts +3 -0
- package/dist/state-machines/query-running/services.js +17 -0
- package/dist/state-machines/query-running/services.js.map +1 -0
- package/dist/state-machines/query-running/types.d.ts +26 -0
- package/dist/state-machines/query-running/types.js +4 -0
- package/dist/state-machines/query-running/types.js.map +1 -0
- package/dist/state-machines/waiting/actions.d.ts +11 -0
- package/dist/state-machines/waiting/actions.js +36 -0
- package/dist/state-machines/waiting/actions.js.map +1 -0
- package/dist/state-machines/waiting/index.d.ts +12 -0
- package/dist/state-machines/waiting/index.js +145 -0
- package/dist/state-machines/waiting/index.js.map +1 -0
- package/dist/state-machines/waiting/services.d.ts +3 -0
- package/dist/state-machines/waiting/services.js +10 -0
- package/dist/state-machines/waiting/services.js.map +1 -0
- package/dist/state-machines/waiting/types.d.ts +12 -0
- package/dist/state-machines/waiting/types.js +4 -0
- package/dist/state-machines/waiting/types.js.map +1 -0
- package/dist/types.d.ts +9 -0
- package/dist/types.js +4 -0
- package/dist/types.js.map +1 -0
- package/dist/utils/adapter/constants.d.ts +5 -0
- package/dist/utils/adapter/constants.js +31 -0
- package/dist/utils/adapter/constants.js.map +1 -0
- package/dist/utils/adapter/create-headers.d.ts +10 -0
- package/dist/utils/adapter/create-headers.js +94 -0
- package/dist/utils/adapter/create-headers.js.map +1 -0
- package/dist/utils/adapter/get-route-path.d.ts +3 -0
- package/dist/utils/adapter/get-route-path.js +22 -0
- package/dist/utils/adapter/get-route-path.js.map +1 -0
- package/dist/utils/adapter/init.d.ts +3 -0
- package/dist/utils/adapter/init.js +183 -0
- package/dist/utils/adapter/init.js.map +1 -0
- package/dist/utils/adapter/manager.d.ts +9 -0
- package/dist/utils/adapter/manager.js +554 -0
- package/dist/utils/adapter/manager.js.map +1 -0
- package/dist/utils/adapter/no-op-manager.d.ts +2 -0
- package/dist/utils/adapter/no-op-manager.js +18 -0
- package/dist/utils/adapter/no-op-manager.js.map +1 -0
- package/dist/utils/adapter/types.d.ts +282 -0
- package/dist/utils/adapter/types.js +4 -0
- package/dist/utils/adapter/types.js.map +1 -0
- package/dist/utils/api-browser-docs.d.ts +272 -0
- package/dist/utils/api-browser-docs.js +318 -0
- package/dist/utils/api-browser-docs.js.map +1 -0
- package/dist/utils/api-node-docs.d.ts +470 -0
- package/dist/utils/api-node-docs.js +519 -0
- package/dist/utils/api-node-docs.js.map +1 -0
- package/dist/utils/api-node-helpers-docs.js +322 -0
- package/dist/utils/api-node-helpers-docs.js.map +1 -0
- package/dist/utils/api-runner-error-parser.d.ts +5 -0
- package/dist/utils/api-runner-error-parser.js +63 -0
- package/dist/utils/api-runner-error-parser.js.map +1 -0
- package/dist/utils/api-runner-node.js +663 -0
- package/dist/utils/api-runner-node.js.map +1 -0
- package/dist/utils/app-data.d.ts +2 -0
- package/dist/utils/app-data.js +15 -0
- package/dist/utils/app-data.js.map +1 -0
- package/dist/utils/assert-store.d.ts +2 -0
- package/dist/utils/assert-store.js +12 -0
- package/dist/utils/assert-store.js.map +1 -0
- package/dist/utils/babel/babel-module-exports-helpers.d.ts +22 -0
- package/dist/utils/babel/babel-module-exports-helpers.js +48 -0
- package/dist/utils/babel/babel-module-exports-helpers.js.map +1 -0
- package/dist/utils/babel/babel-plugin-add-slice-placeholder-location.d.ts +10 -0
- package/dist/utils/babel/babel-plugin-add-slice-placeholder-location.js +48 -0
- package/dist/utils/babel/babel-plugin-add-slice-placeholder-location.js.map +1 -0
- package/dist/utils/babel/babel-plugin-remove-api.d.ts +5 -0
- package/dist/utils/babel/babel-plugin-remove-api.js +148 -0
- package/dist/utils/babel/babel-plugin-remove-api.js.map +1 -0
- package/dist/utils/babel/find-slices.d.ts +8 -0
- package/dist/utils/babel/find-slices.js +68 -0
- package/dist/utils/babel/find-slices.js.map +1 -0
- package/dist/utils/babel-loader-helpers.d.ts +19 -0
- package/dist/utils/babel-loader-helpers.js +158 -0
- package/dist/utils/babel-loader-helpers.js.map +1 -0
- package/dist/utils/babel-loader.d.ts +8 -0
- package/dist/utils/babel-loader.js +158 -0
- package/dist/utils/babel-loader.js.map +1 -0
- package/dist/utils/babel-parse-to-ast.d.ts +4 -0
- package/dist/utils/babel-parse-to-ast.js +34 -0
- package/dist/utils/babel-parse-to-ast.js.map +1 -0
- package/dist/utils/batcher.d.ts +15 -0
- package/dist/utils/batcher.js +46 -0
- package/dist/utils/batcher.js.map +1 -0
- package/dist/utils/browserslist.d.ts +2 -0
- package/dist/utils/browserslist.js +38 -0
- package/dist/utils/browserslist.js.map +1 -0
- package/dist/utils/cache-lmdb.d.ts +19 -0
- package/dist/utils/cache-lmdb.js +88 -0
- package/dist/utils/cache-lmdb.js.map +1 -0
- package/dist/utils/cache.d.ts +17 -0
- package/dist/utils/cache.js +77 -0
- package/dist/utils/cache.js.map +1 -0
- package/dist/utils/call-deferred-api.d.ts +8 -0
- package/dist/utils/call-deferred-api.js +35 -0
- package/dist/utils/call-deferred-api.js.map +1 -0
- package/dist/utils/changed-pages.d.ts +6 -0
- package/dist/utils/changed-pages.js +45 -0
- package/dist/utils/changed-pages.js.map +1 -0
- package/dist/utils/clear-require-cache.d.ts +1 -0
- package/dist/utils/clear-require-cache.js +24 -0
- package/dist/utils/clear-require-cache.js.map +1 -0
- package/dist/utils/client-assets-for-template.d.ts +9 -0
- package/dist/utils/client-assets-for-template.js +141 -0
- package/dist/utils/client-assets-for-template.js.map +1 -0
- package/dist/utils/create-node-id.d.ts +24 -0
- package/dist/utils/create-node-id.js +67 -0
- package/dist/utils/create-node-id.js.map +1 -0
- package/dist/utils/create-schema-customization.d.ts +6 -0
- package/dist/utils/create-schema-customization.js +25 -0
- package/dist/utils/create-schema-customization.js.map +1 -0
- package/dist/utils/detect-node-mutations.d.ts +4 -0
- package/dist/utils/detect-node-mutations.js +134 -0
- package/dist/utils/detect-node-mutations.js.map +1 -0
- package/dist/utils/detect-port-in-use-and-prompt.d.ts +1 -0
- package/dist/utils/detect-port-in-use-and-prompt.js +31 -0
- package/dist/utils/detect-port-in-use-and-prompt.js.map +1 -0
- package/dist/utils/dev-ssr/parse-error.d.ts +22 -0
- package/dist/utils/dev-ssr/parse-error.js +119 -0
- package/dist/utils/dev-ssr/parse-error.js.map +1 -0
- package/dist/utils/dev-ssr/render-dev-html-child.d.ts +13 -0
- package/dist/utils/dev-ssr/render-dev-html-child.js +47 -0
- package/dist/utils/dev-ssr/render-dev-html-child.js.map +1 -0
- package/dist/utils/dev-ssr/render-dev-html.d.ts +23 -0
- package/dist/utils/dev-ssr/render-dev-html.js +227 -0
- package/dist/utils/dev-ssr/render-dev-html.js.map +1 -0
- package/dist/utils/develop-preload-headers.d.ts +7 -0
- package/dist/utils/develop-preload-headers.js +64 -0
- package/dist/utils/develop-preload-headers.js.map +1 -0
- package/dist/utils/did-you-mean.d.ts +3 -0
- package/dist/utils/did-you-mean.js +21 -0
- package/dist/utils/did-you-mean.js.map +1 -0
- package/dist/utils/engine-context.d.ts +5 -0
- package/dist/utils/engine-context.js +19 -0
- package/dist/utils/engine-context.js.map +1 -0
- package/dist/utils/engines-fs-provider.d.ts +9 -0
- package/dist/utils/engines-fs-provider.js +24 -0
- package/dist/utils/engines-fs-provider.js.map +1 -0
- package/dist/utils/engines-helpers.d.ts +10 -0
- package/dist/utils/engines-helpers.js +48 -0
- package/dist/utils/engines-helpers.js.map +1 -0
- package/dist/utils/ensure-file-content.d.ts +1 -0
- package/dist/utils/ensure-file-content.js +19 -0
- package/dist/utils/ensure-file-content.js.map +1 -0
- package/dist/utils/eslint/required.js +10 -0
- package/dist/utils/eslint/required.js.map +1 -0
- package/dist/utils/eslint-config.d.ts +3 -0
- package/dist/utils/eslint-config.js +136 -0
- package/dist/utils/eslint-config.js.map +1 -0
- package/dist/utils/eslint-rules/limited-exports-page-templates.d.ts +1 -0
- package/dist/utils/eslint-rules/limited-exports-page-templates.js +183 -0
- package/dist/utils/eslint-rules/limited-exports-page-templates.js.map +1 -0
- package/dist/utils/eslint-rules/no-anonymous-exports-page-templates.d.ts +1 -0
- package/dist/utils/eslint-rules/no-anonymous-exports-page-templates.js +75 -0
- package/dist/utils/eslint-rules/no-anonymous-exports-page-templates.js.map +1 -0
- package/dist/utils/eslint-rules-helpers.d.ts +4 -0
- package/dist/utils/eslint-rules-helpers.js +22 -0
- package/dist/utils/eslint-rules-helpers.js.map +1 -0
- package/dist/utils/express-middlewares.d.ts +4 -0
- package/dist/utils/express-middlewares.js +57 -0
- package/dist/utils/express-middlewares.js.map +1 -0
- package/dist/utils/extract-undefined-global.d.ts +4 -0
- package/dist/utils/extract-undefined-global.js +15 -0
- package/dist/utils/extract-undefined-global.js.map +1 -0
- package/dist/utils/fast-refresh-module.d.ts +22 -0
- package/dist/utils/fast-refresh-module.js +53 -0
- package/dist/utils/fast-refresh-module.js.map +1 -0
- package/dist/utils/feedback.d.ts +5 -0
- package/dist/utils/feedback.js +159 -0
- package/dist/utils/feedback.js.map +1 -0
- package/dist/utils/find-page-by-path.d.ts +2 -0
- package/dist/utils/find-page-by-path.js +96 -0
- package/dist/utils/find-page-by-path.js.map +1 -0
- package/dist/utils/flags.d.ts +41 -0
- package/dist/utils/flags.js +92 -0
- package/dist/utils/flags.js.map +1 -0
- package/dist/utils/gatsby-cloud-config.d.ts +4 -0
- package/dist/utils/gatsby-cloud-config.js +15 -0
- package/dist/utils/gatsby-cloud-config.js.map +1 -0
- package/dist/utils/gatsby-dependents.d.ts +8 -0
- package/dist/utils/gatsby-dependents.js +51 -0
- package/dist/utils/gatsby-dependents.js.map +1 -0
- package/dist/utils/gatsby-webpack-stats-extractor.d.ts +7 -0
- package/dist/utils/gatsby-webpack-stats-extractor.js +136 -0
- package/dist/utils/gatsby-webpack-stats-extractor.js.map +1 -0
- package/dist/utils/gatsby-webpack-virtual-modules.d.ts +6 -0
- package/dist/utils/gatsby-webpack-virtual-modules.js +45 -0
- package/dist/utils/gatsby-webpack-virtual-modules.js.map +1 -0
- package/dist/utils/get-cache.d.ts +2 -0
- package/dist/utils/get-cache.js +18 -0
- package/dist/utils/get-cache.js.map +1 -0
- package/dist/utils/get-latest-gatsby-files.d.ts +8 -0
- package/dist/utils/get-latest-gatsby-files.js +93 -0
- package/dist/utils/get-latest-gatsby-files.js.map +1 -0
- package/dist/utils/get-page-data.d.ts +3 -0
- package/dist/utils/get-page-data.js +88 -0
- package/dist/utils/get-page-data.js.map +1 -0
- package/dist/utils/get-public-path.d.ts +5 -0
- package/dist/utils/get-public-path.js +19 -0
- package/dist/utils/get-public-path.js.map +1 -0
- package/dist/utils/get-server-data.d.ts +19 -0
- package/dist/utils/get-server-data.js +29 -0
- package/dist/utils/get-server-data.js.map +1 -0
- package/dist/utils/get-ssl-cert.d.ts +9 -0
- package/dist/utils/get-ssl-cert.js +95 -0
- package/dist/utils/get-ssl-cert.js.map +1 -0
- package/dist/utils/get-static-dir.d.ts +12 -0
- package/dist/utils/get-static-dir.js +60 -0
- package/dist/utils/get-static-dir.js.map +1 -0
- package/dist/utils/get-value-at.d.ts +1 -0
- package/dist/utils/get-value-at.js +22 -0
- package/dist/utils/get-value-at.js.map +1 -0
- package/dist/utils/graphql-typegen/file-writes.d.ts +5 -0
- package/dist/utils/graphql-typegen/file-writes.js +63 -0
- package/dist/utils/graphql-typegen/file-writes.js.map +1 -0
- package/dist/utils/graphql-typegen/ts-codegen.d.ts +5 -0
- package/dist/utils/graphql-typegen/ts-codegen.js +136 -0
- package/dist/utils/graphql-typegen/ts-codegen.js.map +1 -0
- package/dist/utils/graphql-typegen/utils.d.ts +11 -0
- package/dist/utils/graphql-typegen/utils.js +70 -0
- package/dist/utils/graphql-typegen/utils.js.map +1 -0
- package/dist/utils/handle-flags.d.ts +8 -0
- package/dist/utils/handle-flags.js +212 -0
- package/dist/utils/handle-flags.js.map +1 -0
- package/dist/utils/import-gatsby-plugin.d.ts +11 -0
- package/dist/utils/import-gatsby-plugin.js +40 -0
- package/dist/utils/import-gatsby-plugin.js.map +1 -0
- package/dist/utils/is-32-bit-integer.d.ts +1 -0
- package/dist/utils/is-32-bit-integer.js +8 -0
- package/dist/utils/is-32-bit-integer.js.map +1 -0
- package/dist/utils/is-near-match.d.ts +1 -0
- package/dist/utils/is-near-match.js +10 -0
- package/dist/utils/is-near-match.js.map +1 -0
- package/dist/utils/jobs/manager.d.ts +34 -0
- package/dist/utils/jobs/manager.js +313 -0
- package/dist/utils/jobs/manager.js.map +1 -0
- package/dist/utils/jobs/types.d.ts +63 -0
- package/dist/utils/jobs/types.js +32 -0
- package/dist/utils/jobs/types.js.map +1 -0
- package/dist/utils/jobs/worker-messaging.d.ts +10 -0
- package/dist/utils/jobs/worker-messaging.js +114 -0
- package/dist/utils/jobs/worker-messaging.js.map +1 -0
- package/dist/utils/js-chunk-names.d.ts +1 -0
- package/dist/utils/js-chunk-names.js +72 -0
- package/dist/utils/js-chunk-names.js.map +1 -0
- package/dist/utils/loading-indicator.d.ts +3 -0
- package/dist/utils/loading-indicator.js +44 -0
- package/dist/utils/loading-indicator.js.map +1 -0
- package/dist/utils/local-eslint-config-finder.d.ts +1 -0
- package/dist/utils/local-eslint-config-finder.js +31 -0
- package/dist/utils/local-eslint-config-finder.js.map +1 -0
- package/dist/utils/merge-gatsby-config.d.ts +28 -0
- package/dist/utils/merge-gatsby-config.js +43 -0
- package/dist/utils/merge-gatsby-config.js.map +1 -0
- package/dist/utils/mett.d.ts +10 -0
- package/dist/utils/mett.js +42 -0
- package/dist/utils/mett.js.map +1 -0
- package/dist/utils/module-resolver.d.ts +2 -0
- package/dist/utils/module-resolver.js +24 -0
- package/dist/utils/module-resolver.js.map +1 -0
- package/dist/utils/node-manifest.d.ts +46 -0
- package/dist/utils/node-manifest.js +367 -0
- package/dist/utils/node-manifest.js.map +1 -0
- package/dist/utils/nodes.d.ts +13 -0
- package/dist/utils/nodes.js +62 -0
- package/dist/utils/nodes.js.map +1 -0
- package/dist/utils/normalize-path.d.ts +2 -0
- package/dist/utils/normalize-path.js +11 -0
- package/dist/utils/normalize-path.js.map +1 -0
- package/dist/utils/page-data-helpers.d.ts +23 -0
- package/dist/utils/page-data-helpers.js +76 -0
- package/dist/utils/page-data-helpers.js.map +1 -0
- package/dist/utils/page-data.d.ts +39 -0
- package/dist/utils/page-data.js +366 -0
- package/dist/utils/page-data.js.map +1 -0
- package/dist/utils/page-mode.d.ts +18 -0
- package/dist/utils/page-mode.js +124 -0
- package/dist/utils/page-mode.js.map +1 -0
- package/dist/utils/page-ssr-module/bundle-webpack.d.ts +18 -0
- package/dist/utils/page-ssr-module/bundle-webpack.js +209 -0
- package/dist/utils/page-ssr-module/bundle-webpack.js.map +1 -0
- package/dist/utils/page-ssr-module/entry.d.ts +61 -0
- package/dist/utils/page-ssr-module/entry.js +344 -0
- package/dist/utils/page-ssr-module/entry.js.map +1 -0
- package/dist/utils/page-ssr-module/lambda.d.ts +3 -0
- package/dist/utils/page-ssr-module/lambda.js +401 -0
- package/dist/utils/page-ssr-module/lambda.js.map +1 -0
- package/dist/utils/parcel/compile-gatsby-files.d.ts +26 -0
- package/dist/utils/parcel/compile-gatsby-files.js +271 -0
- package/dist/utils/parcel/compile-gatsby-files.js.map +1 -0
- package/dist/utils/path.d.ts +5 -0
- package/dist/utils/path.js +55 -0
- package/dist/utils/path.js.map +1 -0
- package/dist/utils/prepare-regex.d.ts +1 -0
- package/dist/utils/prepare-regex.js +13 -0
- package/dist/utils/prepare-regex.js.map +1 -0
- package/dist/utils/prepare-urls.d.ts +7 -0
- package/dist/utils/prepare-urls.js +58 -0
- package/dist/utils/prepare-urls.js.map +1 -0
- package/dist/utils/print-instructions.d.ts +2 -0
- package/dist/utils/print-instructions.js +42 -0
- package/dist/utils/print-instructions.js.map +1 -0
- package/dist/utils/rank-route.d.ts +1 -0
- package/dist/utils/rank-route.js +26 -0
- package/dist/utils/rank-route.js.map +1 -0
- package/dist/utils/reach-router-add-basecontext-export-loader.d.ts +1 -0
- package/dist/utils/reach-router-add-basecontext-export-loader.js +23 -0
- package/dist/utils/reach-router-add-basecontext-export-loader.js.map +1 -0
- package/dist/utils/report-once.d.ts +1 -0
- package/dist/utils/report-once.js +17 -0
- package/dist/utils/report-once.js.map +1 -0
- package/dist/utils/sanitize-node.d.ts +12 -0
- package/dist/utils/sanitize-node.js +87 -0
- package/dist/utils/sanitize-node.js.map +1 -0
- package/dist/utils/show-experiment-notice.d.ts +6 -0
- package/dist/utils/show-experiment-notice.js +51 -0
- package/dist/utils/show-experiment-notice.js.map +1 -0
- package/dist/utils/slices/stitching.d.ts +4 -0
- package/dist/utils/slices/stitching.js +92 -0
- package/dist/utils/slices/stitching.js.map +1 -0
- package/dist/utils/slices.d.ts +2 -0
- package/dist/utils/slices.js +9 -0
- package/dist/utils/slices.js.map +1 -0
- package/dist/utils/source-nodes-api-runner.d.ts +8 -0
- package/dist/utils/source-nodes-api-runner.js +23 -0
- package/dist/utils/source-nodes-api-runner.js.map +1 -0
- package/dist/utils/source-nodes.d.ts +11 -0
- package/dist/utils/source-nodes.js +150 -0
- package/dist/utils/source-nodes.js.map +1 -0
- package/dist/utils/stack-trace-utils.d.ts +24 -0
- package/dist/utils/stack-trace-utils.js +113 -0
- package/dist/utils/stack-trace-utils.js.map +1 -0
- package/dist/utils/start-server.d.ts +22 -0
- package/dist/utils/start-server.js +722 -0
- package/dist/utils/start-server.js.map +1 -0
- package/dist/utils/state-machine-logging.d.ts +4 -0
- package/dist/utils/state-machine-logging.js +47 -0
- package/dist/utils/state-machine-logging.js.map +1 -0
- package/dist/utils/static-query-utils.d.ts +13 -0
- package/dist/utils/static-query-utils.js +57 -0
- package/dist/utils/static-query-utils.js.map +1 -0
- package/dist/utils/test-import-error.d.ts +1 -0
- package/dist/utils/test-import-error.js +18 -0
- package/dist/utils/test-import-error.js.map +1 -0
- package/dist/utils/tracer/index.d.ts +12 -0
- package/dist/utils/tracer/index.js +42 -0
- package/dist/utils/tracer/index.js.map +1 -0
- package/dist/utils/tracer/jaeger-local.d.ts +4 -0
- package/dist/utils/tracer/jaeger-local.js +32 -0
- package/dist/utils/tracer/jaeger-local.js.map +1 -0
- package/dist/utils/tracer/zipkin-local.d.ts +11 -0
- package/dist/utils/tracer/zipkin-local.js +87 -0
- package/dist/utils/tracer/zipkin-local.js.map +1 -0
- package/dist/utils/tracer/zipkin-types.d.js +14 -0
- package/dist/utils/tracer/zipkin-types.d.js.map +1 -0
- package/dist/utils/validate-component.d.ts +23 -0
- package/dist/utils/validate-component.js +99 -0
- package/dist/utils/validate-component.js.map +1 -0
- package/dist/utils/validate-engines/child.d.ts +1 -0
- package/dist/utils/validate-engines/child.js +74 -0
- package/dist/utils/validate-engines/child.js.map +1 -0
- package/dist/utils/validate-engines/index.d.ts +2 -0
- package/dist/utils/validate-engines/index.js +48 -0
- package/dist/utils/validate-engines/index.js.map +1 -0
- package/dist/utils/wait-until-jobs-complete.d.ts +2 -0
- package/dist/utils/wait-until-jobs-complete.js +30 -0
- package/dist/utils/wait-until-jobs-complete.js.map +1 -0
- package/dist/utils/webpack/bundle.d.ts +9 -0
- package/dist/utils/webpack/bundle.js +41 -0
- package/dist/utils/webpack/bundle.js.map +1 -0
- package/dist/utils/webpack/get-ssr-chunk-hashes.d.ts +9 -0
- package/dist/utils/webpack/get-ssr-chunk-hashes.js +55 -0
- package/dist/utils/webpack/get-ssr-chunk-hashes.js.map +1 -0
- package/dist/utils/webpack/loaders/client-components-requires-writer-loader.d.ts +1 -0
- package/dist/utils/webpack/loaders/client-components-requires-writer-loader.js +22 -0
- package/dist/utils/webpack/loaders/client-components-requires-writer-loader.js.map +1 -0
- package/dist/utils/webpack/loaders/partial-hydration-reference-loader.d.ts +1 -0
- package/dist/utils/webpack/loaders/partial-hydration-reference-loader.js +127 -0
- package/dist/utils/webpack/loaders/partial-hydration-reference-loader.js.map +1 -0
- package/dist/utils/webpack/loaders/webpack-remove-exports-loader.d.ts +1 -0
- package/dist/utils/webpack/loaders/webpack-remove-exports-loader.js +40 -0
- package/dist/utils/webpack/loaders/webpack-remove-exports-loader.js.map +1 -0
- package/dist/utils/webpack/plugins/cache-folder-resolver.d.ts +25 -0
- package/dist/utils/webpack/plugins/cache-folder-resolver.js +111 -0
- package/dist/utils/webpack/plugins/cache-folder-resolver.js.map +1 -0
- package/dist/utils/webpack/plugins/corejs-resolver.d.ts +12 -0
- package/dist/utils/webpack/plugins/corejs-resolver.js +66 -0
- package/dist/utils/webpack/plugins/corejs-resolver.js.map +1 -0
- package/dist/utils/webpack/plugins/force-css-hmr-for-edge-cases.d.ts +22 -0
- package/dist/utils/webpack/plugins/force-css-hmr-for-edge-cases.js +88 -0
- package/dist/utils/webpack/plugins/force-css-hmr-for-edge-cases.js.map +1 -0
- package/dist/utils/webpack/plugins/partial-hydration.d.ts +26 -0
- package/dist/utils/webpack/plugins/partial-hydration.js +362 -0
- package/dist/utils/webpack/plugins/partial-hydration.js.map +1 -0
- package/dist/utils/webpack/plugins/static-query-mapper.d.ts +13 -0
- package/dist/utils/webpack/plugins/static-query-mapper.js +235 -0
- package/dist/utils/webpack/plugins/static-query-mapper.js.map +1 -0
- package/dist/utils/webpack/plugins/webpack-logging.d.ts +12 -0
- package/dist/utils/webpack/plugins/webpack-logging.js +51 -0
- package/dist/utils/webpack/plugins/webpack-logging.js.map +1 -0
- package/dist/utils/webpack/utils/create-normalized-module-key.d.ts +12 -0
- package/dist/utils/webpack/utils/create-normalized-module-key.js +25 -0
- package/dist/utils/webpack/utils/create-normalized-module-key.js.map +1 -0
- package/dist/utils/webpack/utils/is-file-inside-compilations.d.ts +7 -0
- package/dist/utils/webpack/utils/is-file-inside-compilations.js +37 -0
- package/dist/utils/webpack/utils/is-file-inside-compilations.js.map +1 -0
- package/dist/utils/webpack-error-utils.d.ts +24 -0
- package/dist/utils/webpack-error-utils.js +112 -0
- package/dist/utils/webpack-error-utils.js.map +1 -0
- package/dist/utils/webpack-plugins.d.ts +46 -0
- package/dist/utils/webpack-plugins.js +61 -0
- package/dist/utils/webpack-plugins.js.map +1 -0
- package/dist/utils/webpack-status.d.ts +3 -0
- package/dist/utils/webpack-status.js +21 -0
- package/dist/utils/webpack-status.js.map +1 -0
- package/dist/utils/webpack-utils.d.ts +121 -0
- package/dist/utils/webpack-utils.js +574 -0
- package/dist/utils/webpack-utils.js.map +1 -0
- package/dist/utils/webpack.config.js +804 -0
- package/dist/utils/webpack.config.js.map +1 -0
- package/dist/utils/websocket-manager.d.ts +39 -0
- package/dist/utils/websocket-manager.js +183 -0
- package/dist/utils/websocket-manager.js.map +1 -0
- package/dist/utils/worker/child/index.d.ts +5 -0
- package/dist/utils/worker/child/index.js +35 -0
- package/dist/utils/worker/child/index.js.map +1 -0
- package/dist/utils/worker/child/load-config-and-plugins.d.ts +2 -0
- package/dist/utils/worker/child/load-config-and-plugins.js +28 -0
- package/dist/utils/worker/child/load-config-and-plugins.js.map +1 -0
- package/dist/utils/worker/child/queries.d.ts +7 -0
- package/dist/utils/worker/child/queries.js +84 -0
- package/dist/utils/worker/child/queries.js.map +1 -0
- package/dist/utils/worker/child/render-html.d.ts +49 -0
- package/dist/utils/worker/child/render-html.js +562 -0
- package/dist/utils/worker/child/render-html.js.map +1 -0
- package/dist/utils/worker/child/schema.d.ts +2 -0
- package/dist/utils/worker/child/schema.js +41 -0
- package/dist/utils/worker/child/schema.js.map +1 -0
- package/dist/utils/worker/child/state.d.ts +2 -0
- package/dist/utils/worker/child/state.js +13 -0
- package/dist/utils/worker/child/state.js.map +1 -0
- package/dist/utils/worker/messaging.d.ts +16 -0
- package/dist/utils/worker/messaging.js +9 -0
- package/dist/utils/worker/messaging.js.map +1 -0
- package/dist/utils/worker/pool.d.ts +10 -0
- package/dist/utils/worker/pool.js +122 -0
- package/dist/utils/worker/pool.js.map +1 -0
- package/dist/utils/worker/reporter.d.ts +3 -0
- package/dist/utils/worker/reporter.js +26 -0
- package/dist/utils/worker/reporter.js.map +1 -0
- package/dist/utils/worker/types.d.ts +3 -0
- package/dist/utils/worker/types.js +4 -0
- package/dist/utils/worker/types.js.map +1 -0
- package/graphql.d.ts +2 -0
- package/graphql.js +6 -0
- package/index.d.ts +1906 -0
- package/internal.d.ts +4 -0
- package/internal.js +5 -0
- package/ipc.json +3 -0
- package/package.json +744 -0
- package/reporter.d.ts +4 -0
- package/reporter.js +3 -0
- package/scripts/postinstall.js +7 -0
- package/utils.js +1 -0
- package/webpack.d.ts +3 -0
- package/webpack.js +3 -0
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
exports.__esModule = true;
|
|
5
|
+
exports.removeExportQueryParam = exports.StaticQueryMapper = void 0;
|
|
6
|
+
var _cloneDeep2 = _interopRequireDefault(require("lodash/cloneDeep"));
|
|
7
|
+
var _isEqual2 = _interopRequireDefault(require("lodash/isEqual"));
|
|
8
|
+
var _path = _interopRequireDefault(require("path"));
|
|
9
|
+
var _webpack = require("webpack");
|
|
10
|
+
var _pageData = require("../../page-data");
|
|
11
|
+
var _findSlices = require("../../babel/find-slices");
|
|
12
|
+
var _path2 = require("gatsby-core-utils/path");
|
|
13
|
+
/**
|
|
14
|
+
* Remove the export query param from a path that can
|
|
15
|
+
* a) contain only the ?export= query param
|
|
16
|
+
* b) but also contain ?__contentFilePath&export=
|
|
17
|
+
*/
|
|
18
|
+
const removeExportQueryParam = path => {
|
|
19
|
+
if (!(path !== null && path !== void 0 && path.includes(`?`))) {
|
|
20
|
+
return path;
|
|
21
|
+
}
|
|
22
|
+
const [filePath, queryParams] = path.split(`?`);
|
|
23
|
+
const params = new URLSearchParams(queryParams.replace(/[+]/g, `%2B`));
|
|
24
|
+
params.delete(`export`);
|
|
25
|
+
const paramsString = params.toString().replace(/[+]/g, `%20`);
|
|
26
|
+
return `${filePath}${paramsString ? `?${decodeURIComponent(paramsString)}` : ``}`;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Checks if a module matches a resourcePath
|
|
31
|
+
*/
|
|
32
|
+
exports.removeExportQueryParam = removeExportQueryParam;
|
|
33
|
+
function doesModuleMatchResourcePath(resourcePath, webpackModule) {
|
|
34
|
+
return removeExportQueryParam(webpackModule.resource) === resourcePath;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* A helper to set/get path resolving
|
|
39
|
+
*/
|
|
40
|
+
function getRealPath(cache, componentPath) {
|
|
41
|
+
if (!cache.has(componentPath)) {
|
|
42
|
+
cache.set(componentPath, _path.default.resolve(componentPath));
|
|
43
|
+
}
|
|
44
|
+
return cache.get(componentPath);
|
|
45
|
+
}
|
|
46
|
+
class StaticQueryMapper {
|
|
47
|
+
constructor(store) {
|
|
48
|
+
this.store = store;
|
|
49
|
+
this.name = `StaticQueryMapper`;
|
|
50
|
+
}
|
|
51
|
+
apply(compiler) {
|
|
52
|
+
const {
|
|
53
|
+
components,
|
|
54
|
+
staticQueryComponents,
|
|
55
|
+
componentsUsingSlices,
|
|
56
|
+
program
|
|
57
|
+
} = this.store.getState();
|
|
58
|
+
compiler.hooks.done.tap(this.name, stats => {
|
|
59
|
+
// In dev mode we want to write page-data when compilation succeeds
|
|
60
|
+
if (!stats.hasErrors() && compiler.watchMode) {
|
|
61
|
+
(0, _pageData.enqueueFlush)();
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
compiler.hooks.finishMake.tapPromise({
|
|
65
|
+
name: this.name,
|
|
66
|
+
before: `PartialHydrationPlugin`
|
|
67
|
+
}, async compilation => {
|
|
68
|
+
if (compilation.compiler.parentCompilation) {
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
const entryModules = new Set();
|
|
72
|
+
const gatsbyBrowserPlugins = (0, _path2.slash)(_path.default.join(program.directory, `.cache`, `api-runner-browser-plugins.js`));
|
|
73
|
+
const asyncRequiresPath = (0, _path2.slash)(_path.default.join(program.directory, `.cache`, `_this_is_virtual_fs_path_`, `$virtual`, `async-requires.js`));
|
|
74
|
+
for (const entry of compilation.entries.values()) {
|
|
75
|
+
for (const dependency of entry.dependencies) {
|
|
76
|
+
const mod = compilation.moduleGraph.getModule(dependency);
|
|
77
|
+
entryModules.add(mod);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
const realPathCache = new Map();
|
|
81
|
+
const webpackModulesByStaticQueryId = new Map();
|
|
82
|
+
const webpackModulesByUsedSlicePlaceholderAlias = new Map();
|
|
83
|
+
const componentModules = new Map();
|
|
84
|
+
let asyncRequiresModule;
|
|
85
|
+
for (const webpackModule of compilation.modules) {
|
|
86
|
+
if (!(webpackModule instanceof _webpack.NormalModule)) {
|
|
87
|
+
// the only other type can be CssModule at this stage, which we don't care about
|
|
88
|
+
// this also acts as a type guard, providing fuller typeing for webpackModule
|
|
89
|
+
continue;
|
|
90
|
+
}
|
|
91
|
+
if (doesModuleMatchResourcePath(asyncRequiresPath, webpackModule)) {
|
|
92
|
+
asyncRequiresModule = webpackModule;
|
|
93
|
+
continue;
|
|
94
|
+
}
|
|
95
|
+
if (doesModuleMatchResourcePath(gatsbyBrowserPlugins, webpackModule)) {
|
|
96
|
+
entryModules.add(webpackModule);
|
|
97
|
+
continue;
|
|
98
|
+
}
|
|
99
|
+
for (const staticQuery of staticQueryComponents.values()) {
|
|
100
|
+
const staticQueryComponentPath = getRealPath(realPathCache, staticQuery.componentPath);
|
|
101
|
+
if (!doesModuleMatchResourcePath(staticQueryComponentPath, webpackModule)) {
|
|
102
|
+
continue;
|
|
103
|
+
}
|
|
104
|
+
let set = webpackModulesByStaticQueryId.get(staticQuery.hash);
|
|
105
|
+
if (!set) {
|
|
106
|
+
set = new Set();
|
|
107
|
+
webpackModulesByStaticQueryId.set(staticQuery.hash, set);
|
|
108
|
+
}
|
|
109
|
+
set.add(webpackModule);
|
|
110
|
+
}
|
|
111
|
+
for (const [filePath, slices] of componentsUsingSlices) {
|
|
112
|
+
const componentComponentPath = getRealPath(realPathCache, filePath);
|
|
113
|
+
if (!doesModuleMatchResourcePath(componentComponentPath, webpackModule)) {
|
|
114
|
+
continue;
|
|
115
|
+
}
|
|
116
|
+
webpackModulesByUsedSlicePlaceholderAlias.set(webpackModule, slices);
|
|
117
|
+
}
|
|
118
|
+
for (const component of components.values()) {
|
|
119
|
+
const componentComponentPath = getRealPath(realPathCache, component.componentPath);
|
|
120
|
+
if (!doesModuleMatchResourcePath(componentComponentPath, webpackModule)) {
|
|
121
|
+
continue;
|
|
122
|
+
}
|
|
123
|
+
componentModules.set(webpackModule, component);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
function traverseModule(module, config, visitedModules = new Set()) {
|
|
127
|
+
if (visitedModules.has(module)) {
|
|
128
|
+
return;
|
|
129
|
+
}
|
|
130
|
+
visitedModules.add(module);
|
|
131
|
+
if (module === asyncRequiresModule) {
|
|
132
|
+
return;
|
|
133
|
+
}
|
|
134
|
+
const component = componentModules.get(module);
|
|
135
|
+
if (component) {
|
|
136
|
+
config.onComponent(component);
|
|
137
|
+
// don't return here yet, as component might be imported by another one, and we want to traverse up until we reach async-requires
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
if (entryModules.has(module)) {
|
|
141
|
+
config.onRoot();
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
const incomingConnections = compilation.moduleGraph.getIncomingConnections(module);
|
|
145
|
+
for (const connection of incomingConnections) {
|
|
146
|
+
if (connection.originModule instanceof _webpack.NormalModule) {
|
|
147
|
+
traverseModule(connection.originModule, config, visitedModules);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
const globalStaticQueries = new Set();
|
|
152
|
+
const staticQueriesByComponents = new Map();
|
|
153
|
+
for (const [staticQueryId, modules] of webpackModulesByStaticQueryId.entries()) {
|
|
154
|
+
for (const module of modules) {
|
|
155
|
+
traverseModule(module, {
|
|
156
|
+
onComponent(component) {
|
|
157
|
+
let staticQueriesForComponent = staticQueriesByComponents.get(component.componentPath);
|
|
158
|
+
if (!staticQueriesForComponent) {
|
|
159
|
+
staticQueriesForComponent = new Set();
|
|
160
|
+
staticQueriesByComponents.set(component.componentPath, staticQueriesForComponent);
|
|
161
|
+
}
|
|
162
|
+
staticQueriesForComponent.add(staticQueryId);
|
|
163
|
+
},
|
|
164
|
+
onRoot() {
|
|
165
|
+
globalStaticQueries.add(staticQueryId);
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
let globalSliceUsage = {};
|
|
171
|
+
const slicesByComponents = new Map();
|
|
172
|
+
for (const [module, slices] of webpackModulesByUsedSlicePlaceholderAlias.entries()) {
|
|
173
|
+
traverseModule(module, {
|
|
174
|
+
onComponent(component) {
|
|
175
|
+
slicesByComponents.set(component.componentPath, (0, _findSlices.mergePreviouslyCollectedSlices)(slices, slicesByComponents.get(component.componentPath)));
|
|
176
|
+
},
|
|
177
|
+
onRoot() {
|
|
178
|
+
globalSliceUsage = (0, _findSlices.mergePreviouslyCollectedSlices)(slices, globalSliceUsage);
|
|
179
|
+
}
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
for (const component of components.values()) {
|
|
183
|
+
var _staticQueriesByCompo, _slicesByComponents$g;
|
|
184
|
+
const allStaticQueries = new Set([...globalStaticQueries, ...((_staticQueriesByCompo = staticQueriesByComponents.get(component.componentPath)) !== null && _staticQueriesByCompo !== void 0 ? _staticQueriesByCompo : [])]);
|
|
185
|
+
const staticQueryHashes = Array.from(allStaticQueries).sort();
|
|
186
|
+
const allSlices = (0, _findSlices.mergePreviouslyCollectedSlices)((_slicesByComponents$g = slicesByComponents.get(component.componentPath)) !== null && _slicesByComponents$g !== void 0 ? _slicesByComponents$g : {}, component.isSlice ? {} : (0, _cloneDeep2.default)(globalSliceUsage));
|
|
187
|
+
const slices = Object.keys(allSlices).sort().reduce((obj, key) => {
|
|
188
|
+
obj[key] = allSlices[key];
|
|
189
|
+
return obj;
|
|
190
|
+
}, {});
|
|
191
|
+
const didSlicesChange = !(0, _isEqual2.default)(this.store.getState().slicesByTemplate.get(component.componentPath), slices);
|
|
192
|
+
const didStaticQueriesChange = !(0, _isEqual2.default)(this.store.getState().staticQueriesByTemplate.get(component.componentPath), staticQueryHashes);
|
|
193
|
+
if (didStaticQueriesChange || didSlicesChange) {
|
|
194
|
+
if (component.isSlice) {
|
|
195
|
+
this.store.dispatch({
|
|
196
|
+
type: `ADD_PENDING_SLICE_TEMPLATE_DATA_WRITE`,
|
|
197
|
+
payload: {
|
|
198
|
+
componentPath: component.componentPath,
|
|
199
|
+
sliceNames: component.pages
|
|
200
|
+
}
|
|
201
|
+
});
|
|
202
|
+
} else {
|
|
203
|
+
this.store.dispatch({
|
|
204
|
+
type: `ADD_PENDING_TEMPLATE_DATA_WRITE`,
|
|
205
|
+
payload: {
|
|
206
|
+
componentPath: component.componentPath,
|
|
207
|
+
pages: component.pages
|
|
208
|
+
}
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
if (didSlicesChange) {
|
|
213
|
+
this.store.dispatch({
|
|
214
|
+
type: `SET_SLICES_BY_TEMPLATE`,
|
|
215
|
+
payload: {
|
|
216
|
+
componentPath: component.componentPath,
|
|
217
|
+
slices
|
|
218
|
+
}
|
|
219
|
+
});
|
|
220
|
+
}
|
|
221
|
+
if (didStaticQueriesChange) {
|
|
222
|
+
this.store.dispatch({
|
|
223
|
+
type: `SET_STATIC_QUERIES_BY_TEMPLATE`,
|
|
224
|
+
payload: {
|
|
225
|
+
componentPath: component.componentPath,
|
|
226
|
+
staticQueryHashes
|
|
227
|
+
}
|
|
228
|
+
});
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
});
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
exports.StaticQueryMapper = StaticQueryMapper;
|
|
235
|
+
//# sourceMappingURL=static-query-mapper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"static-query-mapper.js","names":["removeExportQueryParam","path","includes","filePath","queryParams","split","params","URLSearchParams","replace","delete","paramsString","toString","decodeURIComponent","doesModuleMatchResourcePath","resourcePath","webpackModule","resource","getRealPath","cache","componentPath","has","set","resolve","get","StaticQueryMapper","constructor","store","name","apply","compiler","components","staticQueryComponents","componentsUsingSlices","program","getState","hooks","done","tap","stats","hasErrors","watchMode","enqueueFlush","finishMake","tapPromise","before","compilation","parentCompilation","entryModules","Set","gatsbyBrowserPlugins","slash","join","directory","asyncRequiresPath","entry","entries","values","dependency","dependencies","mod","moduleGraph","getModule","add","realPathCache","Map","webpackModulesByStaticQueryId","webpackModulesByUsedSlicePlaceholderAlias","componentModules","asyncRequiresModule","modules","NormalModule","staticQuery","staticQueryComponentPath","hash","slices","componentComponentPath","component","traverseModule","module","config","visitedModules","onComponent","onRoot","incomingConnections","getIncomingConnections","connection","originModule","globalStaticQueries","staticQueriesByComponents","staticQueryId","staticQueriesForComponent","globalSliceUsage","slicesByComponents","mergePreviouslyCollectedSlices","allStaticQueries","staticQueryHashes","Array","from","sort","allSlices","isSlice","Object","keys","reduce","obj","key","didSlicesChange","slicesByTemplate","didStaticQueriesChange","staticQueriesByTemplate","dispatch","type","payload","sliceNames","pages"],"sources":["../../../../src/utils/webpack/plugins/static-query-mapper.ts"],"sourcesContent":["import path from \"path\"\nimport { Store } from \"redux\"\nimport { Compiler, NormalModule } from \"webpack\"\nimport { isEqual, cloneDeep } from \"lodash\"\nimport { enqueueFlush } from \"../../page-data\"\nimport type { IGatsbyState, IGatsbyPageComponent } from \"../../../redux/types\"\nimport {\n ICollectedSlices,\n mergePreviouslyCollectedSlices,\n} from \"../../babel/find-slices\"\nimport { slash } from \"gatsby-core-utils/path\"\n\n/**\n * Remove the export query param from a path that can\n * a) contain only the ?export= query param\n * b) but also contain ?__contentFilePath&export=\n */\nexport const removeExportQueryParam = (\n path: string | undefined\n): string | undefined => {\n if (!path?.includes(`?`)) {\n return path\n }\n const [filePath, queryParams] = path.split(`?`)\n const params = new URLSearchParams(queryParams.replace(/[+]/g, `%2B`))\n params.delete(`export`)\n\n const paramsString = params.toString().replace(/[+]/g, `%20`)\n\n return `${filePath}${\n paramsString ? `?${decodeURIComponent(paramsString)}` : ``\n }`\n}\n\n/**\n * Checks if a module matches a resourcePath\n */\nfunction doesModuleMatchResourcePath(\n resourcePath: string,\n webpackModule: NormalModule\n): boolean {\n return (\n removeExportQueryParam((webpackModule as NormalModule).resource) ===\n resourcePath\n )\n}\n\n/**\n * A helper to set/get path resolving\n */\nfunction getRealPath(\n cache: Map<string, string>,\n componentPath: string\n): string {\n if (!cache.has(componentPath)) {\n cache.set(componentPath, path.resolve(componentPath))\n }\n\n return cache.get(componentPath) as string\n}\n\nexport class StaticQueryMapper {\n private store: Store<IGatsbyState>\n private name: string\n\n constructor(store) {\n this.store = store\n this.name = `StaticQueryMapper`\n }\n\n apply(compiler: Compiler): void {\n const {\n components,\n staticQueryComponents,\n componentsUsingSlices,\n program,\n } = this.store.getState()\n\n compiler.hooks.done.tap(this.name, stats => {\n // In dev mode we want to write page-data when compilation succeeds\n if (!stats.hasErrors() && compiler.watchMode) {\n enqueueFlush()\n }\n })\n\n compiler.hooks.finishMake.tapPromise(\n {\n name: this.name,\n before: `PartialHydrationPlugin`,\n },\n async compilation => {\n if (compilation.compiler.parentCompilation) {\n return\n }\n\n const entryModules = new Set()\n const gatsbyBrowserPlugins = slash(\n path.join(\n program.directory,\n `.cache`,\n `api-runner-browser-plugins.js`\n )\n )\n const asyncRequiresPath = slash(\n path.join(\n program.directory,\n `.cache`,\n `_this_is_virtual_fs_path_`,\n `$virtual`,\n `async-requires.js`\n )\n )\n for (const entry of compilation.entries.values()) {\n for (const dependency of entry.dependencies) {\n const mod = compilation.moduleGraph.getModule(dependency)\n entryModules.add(mod)\n }\n }\n\n const realPathCache = new Map<string, string>()\n\n const webpackModulesByStaticQueryId = new Map<\n string,\n Set<NormalModule>\n >()\n const webpackModulesByUsedSlicePlaceholderAlias = new Map<\n NormalModule,\n ICollectedSlices\n >()\n const componentModules = new Map<NormalModule, IGatsbyPageComponent>()\n let asyncRequiresModule: NormalModule | undefined\n\n for (const webpackModule of compilation.modules) {\n if (!(webpackModule instanceof NormalModule)) {\n // the only other type can be CssModule at this stage, which we don't care about\n // this also acts as a type guard, providing fuller typeing for webpackModule\n continue\n }\n\n if (doesModuleMatchResourcePath(asyncRequiresPath, webpackModule)) {\n asyncRequiresModule = webpackModule\n continue\n }\n\n if (\n doesModuleMatchResourcePath(gatsbyBrowserPlugins, webpackModule)\n ) {\n entryModules.add(webpackModule)\n continue\n }\n\n for (const staticQuery of staticQueryComponents.values()) {\n const staticQueryComponentPath = getRealPath(\n realPathCache,\n staticQuery.componentPath\n )\n\n if (\n !doesModuleMatchResourcePath(\n staticQueryComponentPath,\n webpackModule\n )\n ) {\n continue\n }\n\n let set = webpackModulesByStaticQueryId.get(staticQuery.hash)\n\n if (!set) {\n set = new Set()\n webpackModulesByStaticQueryId.set(staticQuery.hash, set)\n }\n\n set.add(webpackModule)\n }\n\n for (const [filePath, slices] of componentsUsingSlices) {\n const componentComponentPath = getRealPath(realPathCache, filePath)\n\n if (\n !doesModuleMatchResourcePath(\n componentComponentPath,\n webpackModule\n )\n ) {\n continue\n }\n\n webpackModulesByUsedSlicePlaceholderAlias.set(webpackModule, slices)\n }\n\n for (const component of components.values()) {\n const componentComponentPath = getRealPath(\n realPathCache,\n component.componentPath\n )\n\n if (\n !doesModuleMatchResourcePath(\n componentComponentPath,\n webpackModule\n )\n ) {\n continue\n }\n\n componentModules.set(webpackModule, component)\n }\n }\n\n function traverseModule(\n module: NormalModule,\n config: {\n onComponent(component: IGatsbyPageComponent): void\n onRoot(): void\n },\n visitedModules = new Set<NormalModule>()\n ): void {\n if (visitedModules.has(module)) {\n return\n }\n visitedModules.add(module)\n\n if (module === asyncRequiresModule) {\n return\n }\n\n const component = componentModules.get(module)\n if (component) {\n config.onComponent(component)\n // don't return here yet, as component might be imported by another one, and we want to traverse up until we reach async-requires\n }\n\n if (entryModules.has(module)) {\n config.onRoot()\n return\n }\n\n const incomingConnections =\n compilation.moduleGraph.getIncomingConnections(module)\n for (const connection of incomingConnections) {\n if (connection.originModule instanceof NormalModule) {\n traverseModule(connection.originModule, config, visitedModules)\n }\n }\n }\n\n const globalStaticQueries = new Set<string>()\n const staticQueriesByComponents = new Map<string, Set<string>>()\n for (const [\n staticQueryId,\n modules,\n ] of webpackModulesByStaticQueryId.entries()) {\n for (const module of modules) {\n traverseModule(module, {\n onComponent(component: IGatsbyPageComponent) {\n let staticQueriesForComponent = staticQueriesByComponents.get(\n component.componentPath\n )\n if (!staticQueriesForComponent) {\n staticQueriesForComponent = new Set()\n staticQueriesByComponents.set(\n component.componentPath,\n staticQueriesForComponent\n )\n }\n\n staticQueriesForComponent.add(staticQueryId)\n },\n onRoot() {\n globalStaticQueries.add(staticQueryId)\n },\n })\n }\n }\n\n let globalSliceUsage: ICollectedSlices = {}\n const slicesByComponents = new Map<string, ICollectedSlices>()\n for (const [\n module,\n slices,\n ] of webpackModulesByUsedSlicePlaceholderAlias.entries()) {\n traverseModule(module, {\n onComponent(component: IGatsbyPageComponent) {\n slicesByComponents.set(\n component.componentPath,\n mergePreviouslyCollectedSlices(\n slices,\n slicesByComponents.get(component.componentPath)\n )\n )\n },\n onRoot() {\n globalSliceUsage = mergePreviouslyCollectedSlices(\n slices,\n globalSliceUsage\n )\n },\n })\n }\n\n for (const component of components.values()) {\n const allStaticQueries = new Set([\n ...globalStaticQueries,\n ...(staticQueriesByComponents.get(component.componentPath) ?? []),\n ])\n const staticQueryHashes = Array.from(allStaticQueries).sort()\n\n const allSlices = mergePreviouslyCollectedSlices(\n slicesByComponents.get(component.componentPath) ?? {},\n component.isSlice ? {} : cloneDeep(globalSliceUsage)\n )\n\n const slices = Object.keys(allSlices)\n .sort()\n .reduce((obj, key) => {\n obj[key] = allSlices[key]\n return obj\n }, {})\n\n const didSlicesChange = !isEqual(\n this.store.getState().slicesByTemplate.get(component.componentPath),\n slices\n )\n const didStaticQueriesChange = !isEqual(\n this.store\n .getState()\n .staticQueriesByTemplate.get(component.componentPath),\n staticQueryHashes\n )\n\n if (didStaticQueriesChange || didSlicesChange) {\n if (component.isSlice) {\n this.store.dispatch({\n type: `ADD_PENDING_SLICE_TEMPLATE_DATA_WRITE`,\n payload: {\n componentPath: component.componentPath,\n sliceNames: component.pages,\n },\n })\n } else {\n this.store.dispatch({\n type: `ADD_PENDING_TEMPLATE_DATA_WRITE`,\n payload: {\n componentPath: component.componentPath,\n pages: component.pages,\n },\n })\n }\n }\n\n if (didSlicesChange) {\n this.store.dispatch({\n type: `SET_SLICES_BY_TEMPLATE`,\n payload: {\n componentPath: component.componentPath,\n slices,\n },\n })\n }\n\n if (didStaticQueriesChange) {\n this.store.dispatch({\n type: `SET_STATIC_QUERIES_BY_TEMPLATE`,\n payload: {\n componentPath: component.componentPath,\n staticQueryHashes,\n },\n })\n }\n }\n }\n )\n }\n}\n"],"mappings":";;;;;;;AAAA;AAEA;AAEA;AAEA;AAIA;AAEA;AACA;AACA;AACA;AACA;AACO,MAAMA,sBAAsB,GACjCC,IAAwB,IACD;EACvB,IAAI,EAACA,IAAI,aAAJA,IAAI,eAAJA,IAAI,CAAEC,QAAQ,CAAE,GAAE,CAAC,GAAE;IACxB,OAAOD,IAAI;EACb;EACA,MAAM,CAACE,QAAQ,EAAEC,WAAW,CAAC,GAAGH,IAAI,CAACI,KAAK,CAAE,GAAE,CAAC;EAC/C,MAAMC,MAAM,GAAG,IAAIC,eAAe,CAACH,WAAW,CAACI,OAAO,CAAC,MAAM,EAAG,KAAI,CAAC,CAAC;EACtEF,MAAM,CAAC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,KAAK,CAACoF,QAAQ,CAAC;YAClBC,IAAI,EAAG,wBAAuB;YAC9BC,OAAO,EAAE;cACP7F,aAAa,EAAEyD,SAAS,CAACzD,aAAa;cACtCuD;YACF;UACF,CAAC,CAAC;QACJ;QAEA,IAAIkC,sBAAsB,EAAE;UAC1B,IAAI,CAAClF,KAAK,CAACoF,QAAQ,CAAC;YAClBC,IAAI,EAAG,gCAA+B;YACtCC,OAAO,EAAE;cACP7F,aAAa,EAAEyD,SAAS,CAACzD,aAAa;cACtC4E;YACF;UACF,CAAC,CAAC;QACJ;MACF;IACF,CAAC,CACF;EACH;AACF;AAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type reporter from "gatsby-cli/lib/reporter";
|
|
2
|
+
import type { Compiler } from "webpack";
|
|
3
|
+
type Reporter = typeof reporter;
|
|
4
|
+
export declare class WebpackLoggingPlugin {
|
|
5
|
+
private PLUGIN_NAME;
|
|
6
|
+
private rootDir;
|
|
7
|
+
private reporter;
|
|
8
|
+
private isVerbose;
|
|
9
|
+
constructor(rootDir: string, reporter: Reporter, isVerbose?: boolean);
|
|
10
|
+
apply(compiler: Compiler): void;
|
|
11
|
+
}
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
exports.__esModule = true;
|
|
5
|
+
exports.WebpackLoggingPlugin = void 0;
|
|
6
|
+
var _webpack = require("webpack");
|
|
7
|
+
var _resolveFrom = _interopRequireDefault(require("resolve-from"));
|
|
8
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
9
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
10
|
+
class WebpackLoggingPlugin {
|
|
11
|
+
PLUGIN_NAME = `WebpackLogging`;
|
|
12
|
+
isVerbose = false;
|
|
13
|
+
constructor(rootDir, reporter, isVerbose = false) {
|
|
14
|
+
this.rootDir = rootDir;
|
|
15
|
+
this.reporter = reporter;
|
|
16
|
+
this.isVerbose = isVerbose;
|
|
17
|
+
}
|
|
18
|
+
apply(compiler) {
|
|
19
|
+
compiler.options.infrastructureLogging = {
|
|
20
|
+
level: `verbose`,
|
|
21
|
+
debug: /FileSystemInfo/
|
|
22
|
+
};
|
|
23
|
+
compiler.options.profile = true;
|
|
24
|
+
new _webpack.ProgressPlugin({
|
|
25
|
+
profile: true
|
|
26
|
+
}).apply(compiler);
|
|
27
|
+
|
|
28
|
+
// if webpack bundle analyzer is installed lets use it
|
|
29
|
+
const webpackBundleAnalyzerPath = _resolveFrom.default.silent(this.rootDir, `webpack-bundle-analyzer`);
|
|
30
|
+
if (webpackBundleAnalyzerPath) {
|
|
31
|
+
compiler.hooks.beforeRun.tapPromise(this.PLUGIN_NAME, () => Promise.resolve(`${webpackBundleAnalyzerPath}`).then(s => _interopRequireWildcard(require(s))).then(({
|
|
32
|
+
BundleAnalyzerPlugin
|
|
33
|
+
}) => {
|
|
34
|
+
new BundleAnalyzerPlugin({
|
|
35
|
+
analyzerMode: `static`,
|
|
36
|
+
openAnalyzer: false,
|
|
37
|
+
title: compiler.name,
|
|
38
|
+
reportFilename: `report.html`
|
|
39
|
+
}).apply(compiler);
|
|
40
|
+
}));
|
|
41
|
+
}
|
|
42
|
+
compiler.hooks.done.tap(this.PLUGIN_NAME, stats => {
|
|
43
|
+
this.reporter.log(stats.toString({
|
|
44
|
+
colors: true,
|
|
45
|
+
logging: this.isVerbose ? `verbose` : `log`
|
|
46
|
+
}));
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.WebpackLoggingPlugin = WebpackLoggingPlugin;
|
|
51
|
+
//# sourceMappingURL=webpack-logging.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webpack-logging.js","names":["WebpackLoggingPlugin","PLUGIN_NAME","isVerbose","constructor","rootDir","reporter","apply","compiler","options","infrastructureLogging","level","debug","profile","ProgressPlugin","webpackBundleAnalyzerPath","resolveFrom","silent","hooks","beforeRun","tapPromise","then","BundleAnalyzerPlugin","analyzerMode","openAnalyzer","title","name","reportFilename","done","tap","stats","log","toString","colors","logging"],"sources":["../../../../src/utils/webpack/plugins/webpack-logging.ts"],"sourcesContent":["import { ProgressPlugin } from \"webpack\"\nimport resolveFrom from \"resolve-from\"\nimport type reporter from \"gatsby-cli/lib/reporter\"\nimport type { Compiler } from \"webpack\"\n\ntype Reporter = typeof reporter\n\nexport class WebpackLoggingPlugin {\n private PLUGIN_NAME = `WebpackLogging`\n private rootDir: string\n private reporter: Reporter\n private isVerbose = false\n\n constructor(rootDir: string, reporter: Reporter, isVerbose = false) {\n this.rootDir = rootDir\n this.reporter = reporter\n this.isVerbose = isVerbose\n }\n\n apply(compiler: Compiler): void {\n compiler.options.infrastructureLogging = {\n level: `verbose`,\n debug: /FileSystemInfo/,\n }\n compiler.options.profile = true\n\n new ProgressPlugin({\n profile: true,\n }).apply(compiler)\n\n // if webpack bundle analyzer is installed lets use it\n const webpackBundleAnalyzerPath = resolveFrom.silent(\n this.rootDir,\n `webpack-bundle-analyzer`\n )\n if (webpackBundleAnalyzerPath) {\n compiler.hooks.beforeRun.tapPromise(this.PLUGIN_NAME, () =>\n import(webpackBundleAnalyzerPath).then(({ BundleAnalyzerPlugin }) => {\n new BundleAnalyzerPlugin({\n analyzerMode: `static`,\n openAnalyzer: false,\n title: compiler.name,\n reportFilename: `report.html`,\n }).apply(compiler)\n })\n )\n }\n\n compiler.hooks.done.tap(this.PLUGIN_NAME, stats => {\n this.reporter.log(\n stats.toString({\n colors: true,\n logging: this.isVerbose ? `verbose` : `log`,\n })\n )\n })\n }\n}\n"],"mappings":";;;;;AAAA;AACA;AAAsC;AAAA;AAM/B,MAAMA,oBAAoB,CAAC;EACxBC,WAAW,GAAI,gBAAe;EAG9BC,SAAS,GAAG,KAAK;EAEzBC,WAAW,CAACC,OAAe,EAAEC,QAAkB,EAAEH,SAAS,GAAG,KAAK,EAAE;IAClE,IAAI,CAACE,OAAO,GAAGA,OAAO;IACtB,IAAI,CAACC,QAAQ,GAAGA,QAAQ;IACxB,IAAI,CAACH,SAAS,GAAGA,SAAS;EAC5B;EAEAI,KAAK,CAACC,QAAkB,EAAQ;IAC9BA,QAAQ,CAACC,OAAO,CAACC,qBAAqB,GAAG;MACvCC,KAAK,EAAG,SAAQ;MAChBC,KAAK,EAAE;IACT,CAAC;IACDJ,QAAQ,CAACC,OAAO,CAACI,OAAO,GAAG,IAAI;IAE/B,IAAIC,uBAAc,CAAC;MACjBD,OAAO,EAAE;IACX,CAAC,CAAC,CAACN,KAAK,CAACC,QAAQ,CAAC;;IAElB;IACA,MAAMO,yBAAyB,GAAGC,oBAAW,CAACC,MAAM,CAClD,IAAI,CAACZ,OAAO,EACX,yBAAwB,CAC1B;IACD,IAAIU,yBAAyB,EAAE;MAC7BP,QAAQ,CAACU,KAAK,CAACC,SAAS,CAACC,UAAU,CAAC,IAAI,CAAClB,WAAW,EAAE,MACpD,mBAAOa,yBAAyB,mDAAEM,IAAI,CAAC,CAAC;QAAEC;MAAqB,CAAC,KAAK;QACnE,IAAIA,oBAAoB,CAAC;UACvBC,YAAY,EAAG,QAAO;UACtBC,YAAY,EAAE,KAAK;UACnBC,KAAK,EAAEjB,QAAQ,CAACkB,IAAI;UACpBC,cAAc,EAAG;QACnB,CAAC,CAAC,CAACpB,KAAK,CAACC,QAAQ,CAAC;MACpB,CAAC,CAAC,CACH;IACH;IAEAA,QAAQ,CAACU,KAAK,CAACU,IAAI,CAACC,GAAG,CAAC,IAAI,CAAC3B,WAAW,EAAE4B,KAAK,IAAI;MACjD,IAAI,CAACxB,QAAQ,CAACyB,GAAG,CACfD,KAAK,CAACE,QAAQ,CAAC;QACbC,MAAM,EAAE,IAAI;QACZC,OAAO,EAAE,IAAI,CAAC/B,SAAS,GAAI,SAAQ,GAAI;MACzC,CAAC,CAAC,CACH;IACH,CAAC,CAAC;EACJ;AACF;AAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Create a normalized module key that is referenced in both the partial hydration webpack loader and plugin.
|
|
3
|
+
* This solves for module imports that may be differently bundled for different environments (e.g. browser, node).
|
|
4
|
+
*
|
|
5
|
+
* If the module is a local module, the key is the relative path from the project root (e.g. `file://src/components/index.js`).
|
|
6
|
+
* If the module is a node module, the key is the relative path to the module name in `node_modules` (e.g. `file://node_modules/react`).
|
|
7
|
+
*
|
|
8
|
+
* @param resourcePath Absolute path to the resource
|
|
9
|
+
* @param rootContext Absolute path to project root
|
|
10
|
+
* @returns Normalized module key
|
|
11
|
+
*/
|
|
12
|
+
export declare function createNormalizedModuleKey(resourcePath: string, rootContext: string): string;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
exports.__esModule = true;
|
|
5
|
+
exports.createNormalizedModuleKey = createNormalizedModuleKey;
|
|
6
|
+
var _path = _interopRequireDefault(require("path"));
|
|
7
|
+
var _gatsbyCoreUtils = require("gatsby-core-utils");
|
|
8
|
+
/**
|
|
9
|
+
* Create a normalized module key that is referenced in both the partial hydration webpack loader and plugin.
|
|
10
|
+
* This solves for module imports that may be differently bundled for different environments (e.g. browser, node).
|
|
11
|
+
*
|
|
12
|
+
* If the module is a local module, the key is the relative path from the project root (e.g. `file://src/components/index.js`).
|
|
13
|
+
* If the module is a node module, the key is the relative path to the module name in `node_modules` (e.g. `file://node_modules/react`).
|
|
14
|
+
*
|
|
15
|
+
* @param resourcePath Absolute path to the resource
|
|
16
|
+
* @param rootContext Absolute path to project root
|
|
17
|
+
* @returns Normalized module key
|
|
18
|
+
*/
|
|
19
|
+
function createNormalizedModuleKey(resourcePath, rootContext) {
|
|
20
|
+
const rootRelativeFilePath = resourcePath.replace(rootContext, ``);
|
|
21
|
+
const [rootRelativeDir, potentialModuleName] = rootRelativeFilePath.split(_path.default.sep).filter(Boolean);
|
|
22
|
+
const normalizedModuleKey = rootRelativeDir === `node_modules` ? `file://${_path.default.join(rootRelativeDir, potentialModuleName)}` : `file://${rootRelativeFilePath.slice(1)}`;
|
|
23
|
+
return (0, _gatsbyCoreUtils.slash)(normalizedModuleKey);
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=create-normalized-module-key.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-normalized-module-key.js","names":["createNormalizedModuleKey","resourcePath","rootContext","rootRelativeFilePath","replace","rootRelativeDir","potentialModuleName","split","path","sep","filter","Boolean","normalizedModuleKey","join","slice","slash"],"sources":["../../../../src/utils/webpack/utils/create-normalized-module-key.ts"],"sourcesContent":["import path from \"path\"\nimport { slash } from \"gatsby-core-utils\"\n\n/**\n * Create a normalized module key that is referenced in both the partial hydration webpack loader and plugin.\n * This solves for module imports that may be differently bundled for different environments (e.g. browser, node).\n *\n * If the module is a local module, the key is the relative path from the project root (e.g. `file://src/components/index.js`).\n * If the module is a node module, the key is the relative path to the module name in `node_modules` (e.g. `file://node_modules/react`).\n *\n * @param resourcePath Absolute path to the resource\n * @param rootContext Absolute path to project root\n * @returns Normalized module key\n */\nexport function createNormalizedModuleKey(\n resourcePath: string,\n rootContext: string\n): string {\n const rootRelativeFilePath = resourcePath.replace(rootContext, ``)\n const [rootRelativeDir, potentialModuleName] = rootRelativeFilePath\n .split(path.sep)\n .filter(Boolean)\n const normalizedModuleKey =\n rootRelativeDir === `node_modules`\n ? `file://${path.join(rootRelativeDir, potentialModuleName)}`\n : `file://${rootRelativeFilePath.slice(1)}`\n return slash(normalizedModuleKey)\n}\n"],"mappings":";;;;;AAAA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASA,yBAAyB,CACvCC,YAAoB,EACpBC,WAAmB,EACX;EACR,MAAMC,oBAAoB,GAAGF,YAAY,CAACG,OAAO,CAACF,WAAW,EAAG,EAAC,CAAC;EAClE,MAAM,CAACG,eAAe,EAAEC,mBAAmB,CAAC,GAAGH,oBAAoB,CAChEI,KAAK,CAACC,aAAI,CAACC,GAAG,CAAC,CACfC,MAAM,CAACC,OAAO,CAAC;EAClB,MAAMC,mBAAmB,GACvBP,eAAe,KAAM,cAAa,GAC7B,UAASG,aAAI,CAACK,IAAI,CAACR,eAAe,EAAEC,mBAAmB,CAAE,EAAC,GAC1D,UAASH,oBAAoB,CAACW,KAAK,CAAC,CAAC,CAAE,EAAC;EAC/C,OAAO,IAAAC,sBAAK,EAACH,mBAAmB,CAAC;AACnC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Compilation } from "webpack";
|
|
2
|
+
export declare function setFilesFromDevelopHtmlCompilation(developHtmlCompilation: Compilation): void;
|
|
3
|
+
/**
|
|
4
|
+
* Checks if a file is inside either `develop` or `develop-html` compilation. Used to determine if
|
|
5
|
+
* we should generate codeframe for this file for error overlay.
|
|
6
|
+
*/
|
|
7
|
+
export declare function isFileInsideCompilations(absolutePath: string, developBrowserCompilation: Compilation): boolean;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports.isFileInsideCompilations = isFileInsideCompilations;
|
|
5
|
+
exports.setFilesFromDevelopHtmlCompilation = setFilesFromDevelopHtmlCompilation;
|
|
6
|
+
var _webpack = require("webpack");
|
|
7
|
+
const filesInsideDevelopHtmlCompilation = new Set();
|
|
8
|
+
function removeQueryParams(path) {
|
|
9
|
+
return path.split(`?`)[0];
|
|
10
|
+
}
|
|
11
|
+
function setFilesFromDevelopHtmlCompilation(developHtmlCompilation) {
|
|
12
|
+
filesInsideDevelopHtmlCompilation.clear();
|
|
13
|
+
for (const module of developHtmlCompilation.modules) {
|
|
14
|
+
if (module instanceof _webpack.NormalModule && module.resource) {
|
|
15
|
+
filesInsideDevelopHtmlCompilation.add(removeQueryParams(module.resource));
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Checks if a file is inside either `develop` or `develop-html` compilation. Used to determine if
|
|
22
|
+
* we should generate codeframe for this file for error overlay.
|
|
23
|
+
*/
|
|
24
|
+
function isFileInsideCompilations(absolutePath, developBrowserCompilation) {
|
|
25
|
+
if (filesInsideDevelopHtmlCompilation.has(absolutePath)) {
|
|
26
|
+
return true;
|
|
27
|
+
}
|
|
28
|
+
for (const module of developBrowserCompilation.modules) {
|
|
29
|
+
if (module instanceof _webpack.NormalModule && module.resource) {
|
|
30
|
+
if (absolutePath === removeQueryParams(module.resource)) {
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return false;
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=is-file-inside-compilations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-file-inside-compilations.js","names":["filesInsideDevelopHtmlCompilation","Set","removeQueryParams","path","split","setFilesFromDevelopHtmlCompilation","developHtmlCompilation","clear","module","modules","NormalModule","resource","add","isFileInsideCompilations","absolutePath","developBrowserCompilation","has"],"sources":["../../../../src/utils/webpack/utils/is-file-inside-compilations.ts"],"sourcesContent":["import { Compilation, NormalModule } from \"webpack\"\n\nconst filesInsideDevelopHtmlCompilation = new Set<string>()\n\nfunction removeQueryParams(path: string): string {\n return path.split(`?`)[0]\n}\n\nexport function setFilesFromDevelopHtmlCompilation(\n developHtmlCompilation: Compilation\n): void {\n filesInsideDevelopHtmlCompilation.clear()\n\n for (const module of developHtmlCompilation.modules) {\n if (module instanceof NormalModule && module.resource) {\n filesInsideDevelopHtmlCompilation.add(removeQueryParams(module.resource))\n }\n }\n}\n\n/**\n * Checks if a file is inside either `develop` or `develop-html` compilation. Used to determine if\n * we should generate codeframe for this file for error overlay.\n */\nexport function isFileInsideCompilations(\n absolutePath: string,\n developBrowserCompilation: Compilation\n): boolean {\n if (filesInsideDevelopHtmlCompilation.has(absolutePath)) {\n return true\n }\n\n for (const module of developBrowserCompilation.modules) {\n if (module instanceof NormalModule && module.resource) {\n if (absolutePath === removeQueryParams(module.resource)) {\n return true\n }\n }\n }\n\n return false\n}\n"],"mappings":";;;;;AAAA;AAEA,MAAMA,iCAAiC,GAAG,IAAIC,GAAG,EAAU;AAE3D,SAASC,iBAAiB,CAACC,IAAY,EAAU;EAC/C,OAAOA,IAAI,CAACC,KAAK,CAAE,GAAE,CAAC,CAAC,CAAC,CAAC;AAC3B;AAEO,SAASC,kCAAkC,CAChDC,sBAAmC,EAC7B;EACNN,iCAAiC,CAACO,KAAK,EAAE;EAEzC,KAAK,MAAMC,MAAM,IAAIF,sBAAsB,CAACG,OAAO,EAAE;IACnD,IAAID,MAAM,YAAYE,qBAAY,IAAIF,MAAM,CAACG,QAAQ,EAAE;MACrDX,iCAAiC,CAACY,GAAG,CAACV,iBAAiB,CAACM,MAAM,CAACG,QAAQ,CAAC,CAAC;IAC3E;EACF;AACF;;AAEA;AACA;AACA;AACA;AACO,SAASE,wBAAwB,CACtCC,YAAoB,EACpBC,yBAAsC,EAC7B;EACT,IAAIf,iCAAiC,CAACgB,GAAG,CAACF,YAAY,CAAC,EAAE;IACvD,OAAO,IAAI;EACb;EAEA,KAAK,MAAMN,MAAM,IAAIO,yBAAyB,CAACN,OAAO,EAAE;IACtD,IAAID,MAAM,YAAYE,qBAAY,IAAIF,MAAM,CAACG,QAAQ,EAAE;MACrD,IAAIG,YAAY,KAAKZ,iBAAiB,CAACM,MAAM,CAACG,QAAQ,CAAC,EAAE;QACvD,OAAO,IAAI;MACb;IACF;EACF;EAEA,OAAO,KAAK;AACd"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Reporter } from "gatsby-cli/lib/reporter/reporter";
|
|
2
|
+
import { WebpackError, StatsCompilation } from "webpack";
|
|
3
|
+
import { Stage as StageEnum } from "../commands/types";
|
|
4
|
+
interface IFileLocation {
|
|
5
|
+
line: number;
|
|
6
|
+
column: number;
|
|
7
|
+
}
|
|
8
|
+
interface ITransformedWebpackError {
|
|
9
|
+
id: string;
|
|
10
|
+
filePath: string;
|
|
11
|
+
location?: {
|
|
12
|
+
start: IFileLocation;
|
|
13
|
+
end: IFileLocation;
|
|
14
|
+
};
|
|
15
|
+
context: {
|
|
16
|
+
stage: StageEnum;
|
|
17
|
+
stageLabel: string;
|
|
18
|
+
sourceMessage?: string;
|
|
19
|
+
[key: string]: unknown;
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
export declare const structureWebpackErrors: (stage: StageEnum, webpackError: WebpackError | Array<WebpackError>) => Array<ITransformedWebpackError> | ITransformedWebpackError;
|
|
23
|
+
export declare const reportWebpackWarnings: (warnings: StatsCompilation["warnings"], reporter: Reporter) => void;
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
exports.__esModule = true;
|
|
5
|
+
exports.structureWebpackErrors = exports.reportWebpackWarnings = void 0;
|
|
6
|
+
var _types = require("../commands/types");
|
|
7
|
+
var _formatWebpackMessages = _interopRequireDefault(require("react-dev-utils/formatWebpackMessages"));
|
|
8
|
+
const stageCodeToReadableLabel = {
|
|
9
|
+
[_types.Stage.BuildJavascript]: `Generating JavaScript bundles`,
|
|
10
|
+
[_types.Stage.BuildHTML]: `Generating SSR bundle`,
|
|
11
|
+
[_types.Stage.DevelopHTML]: `Generating development SSR bundle`,
|
|
12
|
+
[_types.Stage.Develop]: `Generating development JavaScript bundle`
|
|
13
|
+
};
|
|
14
|
+
const transformWebpackError = (stage, webpackError) => {
|
|
15
|
+
var _castedWebpackError$e, _castedWebpackError$e2, _castedWebpackError$e3, _resource, _castedWebpackError$m;
|
|
16
|
+
const castedWebpackError = webpackError;
|
|
17
|
+
let location;
|
|
18
|
+
if (castedWebpackError.loc && castedWebpackError.loc.start) {
|
|
19
|
+
location = {
|
|
20
|
+
start: castedWebpackError.loc.start,
|
|
21
|
+
end: castedWebpackError.loc.end
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
if (!location && (_castedWebpackError$e = castedWebpackError.error) !== null && _castedWebpackError$e !== void 0 && _castedWebpackError$e.loc) {
|
|
25
|
+
if (castedWebpackError.error.loc.start) {
|
|
26
|
+
location = castedWebpackError.error.loc;
|
|
27
|
+
} else {
|
|
28
|
+
location = {
|
|
29
|
+
start: castedWebpackError.error.loc
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
// try to get location out of stacktrace
|
|
35
|
+
if (!location) {
|
|
36
|
+
const matches = castedWebpackError.message.match(/\((\d+):(\d+)\)/);
|
|
37
|
+
if (matches && matches[1] && matches[2]) {
|
|
38
|
+
location = {
|
|
39
|
+
start: {
|
|
40
|
+
line: Number(matches[1]),
|
|
41
|
+
column: Number(matches[2])
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
let id = `98123`;
|
|
47
|
+
const context = {
|
|
48
|
+
stage,
|
|
49
|
+
stageLabel: stageCodeToReadableLabel[stage],
|
|
50
|
+
// TODO use formatWebpackMessages like in warnings
|
|
51
|
+
sourceMessage: (_castedWebpackError$e2 = (_castedWebpackError$e3 = castedWebpackError.error) === null || _castedWebpackError$e3 === void 0 ? void 0 : _castedWebpackError$e3.message) !== null && _castedWebpackError$e2 !== void 0 ? _castedWebpackError$e2 : castedWebpackError.message
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
// When a module cannot be found we can short circuit
|
|
55
|
+
if (castedWebpackError.name === `ModuleNotFoundError`) {
|
|
56
|
+
var _castedWebpackError$e4, _castedWebpackError$e5;
|
|
57
|
+
const matches = (_castedWebpackError$e4 = (_castedWebpackError$e5 = castedWebpackError.error) === null || _castedWebpackError$e5 === void 0 ? void 0 : _castedWebpackError$e5.message.match(/Can't resolve '(.*?)' in '(.*?)'/m)) !== null && _castedWebpackError$e4 !== void 0 ? _castedWebpackError$e4 : [];
|
|
58
|
+
id = `98124`;
|
|
59
|
+
context.packageName = matches === null || matches === void 0 ? void 0 : matches[1];
|
|
60
|
+
context.sourceMessage = matches === null || matches === void 0 ? void 0 : matches[0];
|
|
61
|
+
|
|
62
|
+
// get Breaking change message out of error
|
|
63
|
+
// it shows extra information for things that changed with webpack
|
|
64
|
+
const BreakingChangeRegex = /BREAKING CHANGE[\D\n\d]+$/;
|
|
65
|
+
if (BreakingChangeRegex.test(castedWebpackError.message)) {
|
|
66
|
+
const breakingMatch = castedWebpackError.message.match(BreakingChangeRegex);
|
|
67
|
+
context.deprecationReason = breakingMatch === null || breakingMatch === void 0 ? void 0 : breakingMatch[0];
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return {
|
|
71
|
+
id,
|
|
72
|
+
filePath: (_resource = castedWebpackError === null || castedWebpackError === void 0 ? void 0 : (_castedWebpackError$m = castedWebpackError.module) === null || _castedWebpackError$m === void 0 ? void 0 : _castedWebpackError$m.resource) !== null && _resource !== void 0 ? _resource : castedWebpackError.file,
|
|
73
|
+
location,
|
|
74
|
+
context
|
|
75
|
+
// We use original error to display stack trace for the most part.
|
|
76
|
+
// In case of webpack error stack will include internals of webpack
|
|
77
|
+
// or one of loaders (for example babel-loader) and doesn't provide
|
|
78
|
+
// much value to user, so it's purposely omitted.
|
|
79
|
+
|
|
80
|
+
// error: webpackError?.error || webpackError,
|
|
81
|
+
};
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
// With the introduction of Head API, the modulePath can have a resourceQuery so this function can be used to remove it
|
|
85
|
+
const removeResourceQuery = moduleName => {
|
|
86
|
+
const moduleNameWithoutQuery = moduleName === null || moduleName === void 0 ? void 0 : moduleName.replace(/(\?|&)export=(default|head)$/, ``);
|
|
87
|
+
return moduleNameWithoutQuery;
|
|
88
|
+
};
|
|
89
|
+
const structureWebpackErrors = (stage, webpackError) => {
|
|
90
|
+
if (Array.isArray(webpackError)) {
|
|
91
|
+
return webpackError.map(e => transformWebpackError(stage, e));
|
|
92
|
+
}
|
|
93
|
+
return transformWebpackError(stage, webpackError);
|
|
94
|
+
};
|
|
95
|
+
exports.structureWebpackErrors = structureWebpackErrors;
|
|
96
|
+
const reportWebpackWarnings = (warnings = [], reporter) => {
|
|
97
|
+
var _warnings$, _warnings$2, _warnings$3;
|
|
98
|
+
let warningMessages = [];
|
|
99
|
+
if (typeof warnings[0] === `string`) {
|
|
100
|
+
warningMessages = warnings;
|
|
101
|
+
} else if ((_warnings$ = warnings[0]) !== null && _warnings$ !== void 0 && _warnings$.message && removeResourceQuery((_warnings$2 = warnings[0]) === null || _warnings$2 === void 0 ? void 0 : _warnings$2.moduleName)) {
|
|
102
|
+
warningMessages = warnings.map(warning => `${removeResourceQuery(warning.moduleName)}\n\n${warning.message}`);
|
|
103
|
+
} else if ((_warnings$3 = warnings[0]) !== null && _warnings$3 !== void 0 && _warnings$3.message) {
|
|
104
|
+
warningMessages = warnings.map(warning => warning.message);
|
|
105
|
+
}
|
|
106
|
+
(0, _formatWebpackMessages.default)({
|
|
107
|
+
errors: [],
|
|
108
|
+
warnings: warningMessages
|
|
109
|
+
}).warnings.forEach(warning => reporter.warn(warning));
|
|
110
|
+
};
|
|
111
|
+
exports.reportWebpackWarnings = reportWebpackWarnings;
|
|
112
|
+
//# sourceMappingURL=webpack-error-utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webpack-error-utils.js","names":["stageCodeToReadableLabel","StageEnum","BuildJavascript","BuildHTML","DevelopHTML","Develop","transformWebpackError","stage","webpackError","castedWebpackError","location","loc","start","end","error","matches","message","match","line","Number","column","id","context","stageLabel","sourceMessage","name","packageName","BreakingChangeRegex","test","breakingMatch","deprecationReason","filePath","module","resource","file","removeResourceQuery","moduleName","moduleNameWithoutQuery","replace","structureWebpackErrors","Array","isArray","map","e","reportWebpackWarnings","warnings","reporter","warningMessages","warning","formatWebpackMessages","errors","forEach","warn"],"sources":["../../src/utils/webpack-error-utils.ts"],"sourcesContent":["import { Reporter } from \"gatsby-cli/lib/reporter/reporter\"\nimport { WebpackError, StatsCompilation, Module, NormalModule } from \"webpack\"\nimport { Stage as StageEnum } from \"../commands/types\"\nimport formatWebpackMessages from \"react-dev-utils/formatWebpackMessages\"\n\nconst stageCodeToReadableLabel: Record<StageEnum, string> = {\n [StageEnum.BuildJavascript]: `Generating JavaScript bundles`,\n [StageEnum.BuildHTML]: `Generating SSR bundle`,\n [StageEnum.DevelopHTML]: `Generating development SSR bundle`,\n [StageEnum.Develop]: `Generating development JavaScript bundle`,\n}\n\ninterface IFileLocation {\n line: number\n column: number\n}\n\ninterface IWebpackError {\n name: string\n message: string\n file?: string\n error?: {\n message: string\n loc?: {\n start: IFileLocation\n end: IFileLocation\n }\n }\n module: Module\n loc?: {\n start: IFileLocation\n end: IFileLocation\n }\n}\n\ninterface ITransformedWebpackError {\n id: string\n filePath: string\n location?: {\n start: IFileLocation\n end: IFileLocation\n }\n context: {\n stage: StageEnum\n stageLabel: string\n sourceMessage?: string\n [key: string]: unknown\n }\n}\n\nconst transformWebpackError = (\n stage: StageEnum,\n webpackError: WebpackError\n): ITransformedWebpackError => {\n const castedWebpackError = webpackError as unknown as IWebpackError\n\n let location\n if (castedWebpackError.loc && castedWebpackError.loc.start) {\n location = {\n start: castedWebpackError.loc.start,\n end: castedWebpackError.loc.end,\n }\n }\n\n if (!location && castedWebpackError.error?.loc) {\n if (castedWebpackError.error.loc.start) {\n location = castedWebpackError.error.loc\n } else {\n location = {\n start: castedWebpackError.error.loc,\n }\n }\n }\n\n // try to get location out of stacktrace\n if (!location) {\n const matches = castedWebpackError.message.match(/\\((\\d+):(\\d+)\\)/)\n if (matches && matches[1] && matches[2]) {\n location = {\n start: {\n line: Number(matches[1]),\n column: Number(matches[2]),\n },\n }\n }\n }\n\n let id = `98123`\n const context: ITransformedWebpackError[\"context\"] = {\n stage,\n stageLabel: stageCodeToReadableLabel[stage],\n // TODO use formatWebpackMessages like in warnings\n sourceMessage:\n castedWebpackError.error?.message ?? castedWebpackError.message,\n }\n\n // When a module cannot be found we can short circuit\n if (castedWebpackError.name === `ModuleNotFoundError`) {\n const matches =\n castedWebpackError.error?.message.match(\n /Can't resolve '(.*?)' in '(.*?)'/m\n ) ?? []\n\n id = `98124`\n context.packageName = matches?.[1]\n context.sourceMessage = matches?.[0]\n\n // get Breaking change message out of error\n // it shows extra information for things that changed with webpack\n const BreakingChangeRegex = /BREAKING CHANGE[\\D\\n\\d]+$/\n if (BreakingChangeRegex.test(castedWebpackError.message)) {\n const breakingMatch =\n castedWebpackError.message.match(BreakingChangeRegex)\n\n context.deprecationReason = breakingMatch?.[0]\n }\n }\n\n return {\n id,\n filePath:\n (castedWebpackError?.module as NormalModule)?.resource ??\n castedWebpackError.file,\n location,\n context,\n // We use original error to display stack trace for the most part.\n // In case of webpack error stack will include internals of webpack\n // or one of loaders (for example babel-loader) and doesn't provide\n // much value to user, so it's purposely omitted.\n\n // error: webpackError?.error || webpackError,\n }\n}\n\n// With the introduction of Head API, the modulePath can have a resourceQuery so this function can be used to remove it\nconst removeResourceQuery = (\n moduleName: string | undefined\n): string | undefined => {\n const moduleNameWithoutQuery = moduleName?.replace(\n /(\\?|&)export=(default|head)$/,\n ``\n )\n\n return moduleNameWithoutQuery\n}\n\nexport const structureWebpackErrors = (\n stage: StageEnum,\n webpackError: WebpackError | Array<WebpackError>\n): Array<ITransformedWebpackError> | ITransformedWebpackError => {\n if (Array.isArray(webpackError)) {\n return webpackError.map(e => transformWebpackError(stage, e))\n }\n\n return transformWebpackError(stage, webpackError)\n}\n\nexport const reportWebpackWarnings = (\n warnings: StatsCompilation[\"warnings\"] = [],\n reporter: Reporter\n): void => {\n let warningMessages: Array<string> = []\n if (typeof warnings[0] === `string`) {\n warningMessages = warnings as unknown as Array<string>\n } else if (\n warnings[0]?.message &&\n removeResourceQuery(warnings[0]?.moduleName)\n ) {\n warningMessages = warnings.map(\n warning =>\n `${removeResourceQuery(warning.moduleName)}\\n\\n${warning.message}`\n )\n } else if (warnings[0]?.message) {\n warningMessages = warnings.map(warning => warning.message)\n }\n\n formatWebpackMessages({\n errors: [],\n warnings: warningMessages,\n }).warnings.forEach(warning => reporter.warn(warning))\n}\n"],"mappings":";;;;;AAEA;AACA;AAEA,MAAMA,wBAAmD,GAAG;EAC1D,CAACC,YAAS,CAACC,eAAe,GAAI,+BAA8B;EAC5D,CAACD,YAAS,CAACE,SAAS,GAAI,uBAAsB;EAC9C,CAACF,YAAS,CAACG,WAAW,GAAI,mCAAkC;EAC5D,CAACH,YAAS,CAACI,OAAO,GAAI;AACxB,CAAC;AAwCD,MAAMC,qBAAqB,GAAG,CAC5BC,KAAgB,EAChBC,YAA0B,KACG;EAAA;EAC7B,MAAMC,kBAAkB,GAAGD,YAAwC;EAEnE,IAAIE,QAAQ;EACZ,IAAID,kBAAkB,CAACE,GAAG,IAAIF,kBAAkB,CAACE,GAAG,CAACC,KAAK,EAAE;IAC1DF,QAAQ,GAAG;MACTE,KA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