gatsby 4.15.0-next.2 → 4.15.2
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/CHANGELOG.md +28 -0
- package/apis.json +2 -1
- package/cache-dir/commonjs/gatsby-browser-entry.js +23 -0
- package/cache-dir/gatsby-browser-entry.js +2 -0
- package/cli.js +0 -0
- package/dist/bootstrap/__mocks__/resolve-module-exports.d.ts +1 -1
- package/dist/bootstrap/create-graphql-runner.d.ts +10 -10
- package/dist/bootstrap/get-config-file.d.ts +4 -4
- package/dist/bootstrap/index.d.ts +10 -10
- package/dist/bootstrap/load-config/index.d.ts +7 -7
- package/dist/bootstrap/load-plugins/index.d.ts +3 -3
- package/dist/bootstrap/load-plugins/load-internal-plugins.d.ts +2 -2
- package/dist/bootstrap/load-plugins/load-internal-plugins.js +5 -1
- package/dist/bootstrap/load-plugins/load-internal-plugins.js.map +1 -1
- package/dist/bootstrap/load-plugins/process-plugin.d.ts +2 -2
- package/dist/bootstrap/load-plugins/resolve-plugin.d.ts +13 -13
- package/dist/bootstrap/load-plugins/types.d.ts +48 -48
- package/dist/bootstrap/load-plugins/utils/check-local-plugin.d.ts +8 -8
- package/dist/bootstrap/load-plugins/utils/create-hash.d.ts +1 -1
- package/dist/bootstrap/load-plugins/utils/create-id.d.ts +10 -10
- package/dist/bootstrap/load-plugins/utils/flatten-plugins.d.ts +2 -2
- package/dist/bootstrap/load-plugins/utils/get-api.d.ts +12 -12
- package/dist/bootstrap/load-plugins/utils/handle-gatsby-cloud.d.ts +6 -6
- package/dist/bootstrap/load-plugins/utils/handle-gatsby-cloud.js +1 -1
- package/dist/bootstrap/load-plugins/utils/handle-gatsby-cloud.js.map +1 -1
- package/dist/bootstrap/load-plugins/utils/normalize.d.ts +5 -5
- package/dist/bootstrap/load-plugins/validate.d.ts +40 -40
- package/dist/bootstrap/prefer-default.d.ts +1 -1
- package/dist/bootstrap/redirects-writer.d.ts +2 -2
- package/dist/bootstrap/remove-stale-jobs.d.ts +2 -2
- package/dist/bootstrap/requires-writer.d.ts +10 -10
- package/dist/bootstrap/resolve-module-exports.d.ts +14 -14
- package/dist/bootstrap/schema-hot-reloader.d.ts +3 -3
- package/dist/cache/cache-fs.d.ts +1 -1
- package/dist/cache/json-file-store.d.ts +8 -8
- package/dist/commands/build-html.d.ts +55 -55
- package/dist/commands/build-javascript.d.ts +4 -4
- package/dist/commands/build-utils.d.ts +8 -8
- package/dist/commands/build.d.ts +1 -1
- package/dist/commands/clean.d.ts +1 -1
- package/dist/commands/develop-process.d.ts +1 -1
- package/dist/commands/develop-process.js.map +1 -1
- package/dist/commands/develop-static.d.ts +3 -3
- package/dist/commands/develop.d.ts +2 -2
- package/dist/commands/feedback.d.ts +1 -1
- package/dist/commands/repl.d.ts +1 -1
- package/dist/commands/serve.d.ts +1 -1
- package/dist/commands/serve.js +8 -1
- package/dist/commands/serve.js.map +1 -1
- package/dist/commands/types.d.ts +48 -48
- package/dist/constants.d.ts +1 -1
- package/dist/datastore/common/iterable.d.ts +51 -51
- package/dist/datastore/common/query.d.ts +69 -69
- package/dist/datastore/datastore.d.ts +4 -4
- package/dist/datastore/in-memory/in-memory-datastore.d.ts +2 -2
- package/dist/datastore/in-memory/indexing.d.ts +79 -79
- package/dist/datastore/in-memory/run-fast-filters.d.ts +27 -27
- package/dist/datastore/index.d.ts +20 -20
- package/dist/datastore/lmdb/lmdb-datastore.d.ts +13 -13
- package/dist/datastore/lmdb/query/common.d.ts +23 -23
- package/dist/datastore/lmdb/query/create-index.d.ts +25 -25
- package/dist/datastore/lmdb/query/filter-using-index.d.ts +43 -43
- package/dist/datastore/lmdb/query/run-query.d.ts +9 -9
- package/dist/datastore/lmdb/query/suggest-index.d.ts +15 -15
- package/dist/datastore/lmdb/updates/nodes-by-type.d.ts +3 -3
- package/dist/datastore/lmdb/updates/nodes.d.ts +5 -5
- package/dist/datastore/types.d.ts +47 -47
- package/dist/internal-plugins/functions/config.d.ts +12 -12
- package/dist/internal-plugins/functions/gatsby-node.d.ts +3 -3
- package/dist/internal-plugins/functions/gatsby-node.js +8 -6
- package/dist/internal-plugins/functions/gatsby-node.js.map +1 -1
- package/dist/internal-plugins/functions/middleware.d.ts +9 -9
- package/dist/internal-plugins/functions/middleware.js +1 -1
- package/dist/internal-plugins/functions/middleware.js.map +1 -1
- package/dist/internal-plugins/partytown/gatsby-browser.js +71 -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 +68 -0
- package/dist/internal-plugins/partytown/gatsby-node.js.map +1 -0
- package/dist/internal-plugins/partytown/gatsby-ssr.js +50 -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 +32 -0
- package/dist/internal-plugins/partytown/proxy.js.map +1 -0
- package/dist/internal.d.ts +5 -5
- package/dist/joi-schemas/joi.d.ts +5 -5
- package/dist/joi-schemas/joi.js +3 -1
- package/dist/joi-schemas/joi.js.map +1 -1
- package/dist/query/error-parser.d.ts +19 -19
- package/dist/query/graphql-errors-codeframe.d.ts +1 -1
- package/dist/query/graphql-runner.d.ts +38 -38
- package/dist/query/graphql-span-tracer.d.ts +19 -19
- package/dist/query/index.d.ts +26 -26
- package/dist/query/query-runner.d.ts +13 -13
- package/dist/query/query-watcher.d.ts +17 -17
- package/dist/query/types.d.ts +35 -35
- package/dist/query/utils.d.ts +4 -4
- package/dist/redux/actions/add-page-dependency.d.ts +7 -7
- package/dist/redux/actions/index.d.ts +14 -14
- package/dist/redux/actions/internal.d.ts +124 -124
- package/dist/redux/actions/restricted.d.ts +293 -293
- package/dist/redux/index.d.ts +20 -20
- package/dist/redux/persist.d.ts +5 -5
- package/dist/redux/plugin-runner.d.ts +1 -1
- package/dist/redux/reducers/babelrc.d.ts +9 -9
- package/dist/redux/reducers/components.d.ts +2 -2
- package/dist/redux/reducers/config.d.ts +2 -2
- package/dist/redux/reducers/definitions.d.ts +2 -2
- package/dist/redux/reducers/flattened-plugins.d.ts +17 -17
- package/dist/redux/reducers/functions.d.ts +2 -2
- package/dist/redux/reducers/html.d.ts +8 -8
- package/dist/redux/reducers/index.d.ts +36 -36
- package/dist/redux/reducers/inference-metadata.d.ts +7 -7
- package/dist/redux/reducers/jobs.d.ts +5 -5
- package/dist/redux/reducers/jobsv2.d.ts +6 -6
- package/dist/redux/reducers/last-action.d.ts +2 -2
- package/dist/redux/reducers/node-manifest.d.ts +2 -2
- package/dist/redux/reducers/nodes-by-type.d.ts +2 -2
- package/dist/redux/reducers/nodes-touched.d.ts +3 -3
- package/dist/redux/reducers/nodes.d.ts +2 -2
- package/dist/redux/reducers/page-data-stats.d.ts +2 -2
- package/dist/redux/reducers/pages.d.ts +2 -2
- package/dist/redux/reducers/pending-page-data-writes.d.ts +4 -4
- package/dist/redux/reducers/program.d.ts +2 -2
- package/dist/redux/reducers/queries.d.ts +26 -26
- package/dist/redux/reducers/redirects.d.ts +2 -2
- package/dist/redux/reducers/resolved-nodes.d.ts +2 -2
- package/dist/redux/reducers/schema-customization.d.ts +23 -23
- package/dist/redux/reducers/schema.d.ts +3 -3
- package/dist/redux/reducers/static-queries-by-template.d.ts +2 -2
- package/dist/redux/reducers/static-query-components.d.ts +2 -2
- package/dist/redux/reducers/status.d.ts +6 -6
- package/dist/redux/reducers/visited-page.d.ts +2 -2
- package/dist/redux/reducers/webpack-compilation-hash.d.ts +2 -2
- package/dist/redux/reducers/webpack.d.ts +2 -2
- package/dist/redux/types.d.ts +806 -804
- package/dist/redux/types.js.map +1 -1
- package/dist/schema/context.d.ts +14 -14
- package/dist/schema/graphql-engine/bundle-webpack.d.ts +5 -5
- package/dist/schema/graphql-engine/entry.d.ts +19 -19
- package/dist/schema/graphql-engine/lmdb-bundling-patch.d.ts +1 -1
- package/dist/schema/graphql-engine/print-plugins.d.ts +2 -2
- package/dist/schema/graphql-engine/webpack-remove-apis-loader.d.ts +1 -1
- package/dist/schema/infer/build-example-data.d.ts +5 -5
- package/dist/schema/infer/inference-metadata.d.ts +72 -72
- package/dist/schema/infer/is-file.d.ts +1 -1
- package/dist/schema/infer/type-conflict-reporter.d.ts +28 -28
- package/dist/schema/print.d.ts +20 -20
- package/dist/schema/resolvers.d.ts +37 -37
- package/dist/schema/schema-composer.d.ts +3 -3
- package/dist/schema/schema-composer.js +3 -0
- package/dist/schema/schema-composer.js.map +1 -1
- package/dist/schema/type-definitions.d.ts +47 -47
- package/dist/schema/types/built-in-types.d.ts +5 -5
- package/dist/schema/types/built-in-types.js +1 -1
- package/dist/schema/types/built-in-types.js.map +1 -1
- package/dist/schema/types/date.d.ts +37 -37
- package/dist/schema/types/derived-types.d.ts +45 -45
- package/dist/schema/types/filter.d.ts +12 -12
- package/dist/schema/types/media.d.ts +2 -0
- package/dist/schema/types/media.js +12 -0
- package/dist/schema/types/media.js.map +1 -0
- package/dist/schema/types/node-interface.d.ts +14 -14
- package/dist/schema/types/pagination.d.ts +16 -16
- package/dist/schema/types/remote-file-interface.d.ts +3 -3
- package/dist/schema/types/sort.d.ts +18 -18
- package/dist/schema/types/type-builders.d.ts +36 -36
- package/dist/services/build-schema.d.ts +2 -2
- package/dist/services/calculate-dirty-queries.d.ts +5 -5
- package/dist/services/create-pages.d.ts +5 -5
- package/dist/services/customize-schema.d.ts +2 -2
- package/dist/services/extract-queries.d.ts +2 -2
- package/dist/services/graphql-typegen.d.ts +2 -2
- package/dist/services/graphql-typegen.js +14 -3
- package/dist/services/graphql-typegen.js.map +1 -1
- package/dist/services/index.d.ts +18 -18
- package/dist/services/initialize.d.ts +8 -8
- package/dist/services/initialize.js +3 -1
- package/dist/services/initialize.js.map +1 -1
- package/dist/services/listen-for-mutations.d.ts +2 -2
- package/dist/services/listen-to-webpack.d.ts +3 -3
- package/dist/services/post-bootstrap.d.ts +2 -2
- package/dist/services/recompile.d.ts +3 -3
- package/dist/services/run-mutation-batch.d.ts +2 -2
- package/dist/services/run-page-queries.d.ts +2 -2
- package/dist/services/run-static-queries.d.ts +2 -2
- package/dist/services/source-nodes.d.ts +5 -5
- package/dist/services/start-webpack-server.d.ts +9 -9
- package/dist/services/start-webpack-server.js +2 -4
- package/dist/services/start-webpack-server.js.map +1 -1
- package/dist/services/types.d.ts +52 -52
- package/dist/services/write-out-redirects.d.ts +2 -2
- package/dist/services/write-out-requires.d.ts +2 -2
- package/dist/state-machines/data-layer/actions.d.ts +8 -8
- package/dist/state-machines/data-layer/index.d.ts +24 -24
- package/dist/state-machines/data-layer/services.d.ts +3 -3
- package/dist/state-machines/data-layer/types.d.ts +27 -27
- package/dist/state-machines/develop/actions.d.ts +40 -40
- package/dist/state-machines/develop/actions.js +23 -3
- package/dist/state-machines/develop/actions.js.map +1 -1
- package/dist/state-machines/develop/index.d.ts +6 -6
- package/dist/state-machines/develop/index.js +6 -3
- package/dist/state-machines/develop/index.js.map +1 -1
- package/dist/state-machines/develop/services.d.ts +3 -3
- package/dist/state-machines/index.d.ts +7 -7
- package/dist/state-machines/query-running/actions.d.ts +9 -9
- package/dist/state-machines/query-running/index.d.ts +7 -7
- package/dist/state-machines/query-running/services.d.ts +3 -3
- package/dist/state-machines/query-running/types.d.ts +26 -26
- package/dist/state-machines/waiting/actions.d.ts +11 -11
- package/dist/state-machines/waiting/index.d.ts +12 -12
- package/dist/state-machines/waiting/services.d.ts +3 -3
- package/dist/state-machines/waiting/types.d.ts +12 -12
- package/dist/types.d.ts +9 -9
- package/dist/utils/api-browser-docs.d.ts +242 -242
- package/dist/utils/api-node-docs.d.ts +470 -470
- package/dist/utils/api-runner-error-parser.d.ts +5 -5
- package/dist/utils/app-data.d.ts +2 -2
- package/dist/utils/assert-store.d.ts +2 -2
- package/dist/utils/babel/babel-module-exports-helpers.d.ts +22 -22
- package/dist/utils/babel/babel-plugin-remove-api.d.ts +5 -5
- package/dist/utils/babel-parse-to-ast.d.ts +4 -4
- package/dist/utils/batcher.d.ts +15 -15
- package/dist/utils/browserslist.d.ts +2 -2
- package/dist/utils/cache-lmdb.d.ts +19 -19
- package/dist/utils/cache.d.ts +17 -17
- package/dist/utils/call-deferred-api.d.ts +8 -8
- package/dist/utils/changed-pages.d.ts +6 -6
- package/dist/utils/clear-require-cache.d.ts +1 -1
- package/dist/utils/client-assets-for-template.d.ts +9 -9
- package/dist/utils/create-node-id.d.ts +24 -24
- package/dist/utils/create-schema-customization.d.ts +6 -6
- package/dist/utils/detect-node-mutations.d.ts +4 -4
- package/dist/utils/detect-port-in-use-and-prompt.d.ts +1 -1
- package/dist/utils/dev-ssr/render-dev-html.d.ts +23 -23
- package/dist/utils/develop-preload-headers.d.ts +7 -7
- package/dist/utils/develop-proxy.d.ts +14 -14
- package/dist/utils/did-you-mean.d.ts +3 -3
- package/dist/utils/did-you-mean.js +1 -1
- package/dist/utils/did-you-mean.js.map +1 -1
- package/dist/utils/engine-context.d.ts +5 -5
- package/dist/utils/engines-fs-provider.d.ts +9 -9
- package/dist/utils/engines-helpers.d.ts +2 -2
- package/dist/utils/eslint-config.d.ts +4 -4
- package/dist/utils/eslint-rules/limited-exports-page-templates.d.ts +1 -1
- package/dist/utils/eslint-rules/no-anonymous-exports-page-templates.d.ts +1 -1
- package/dist/utils/eslint-rules-helpers.d.ts +4 -4
- package/dist/utils/express-middlewares.d.ts +4 -4
- package/dist/utils/fast-refresh-module.d.ts +22 -22
- package/dist/utils/feedback.d.ts +5 -5
- package/dist/utils/find-page-by-path.d.ts +2 -2
- package/dist/utils/flags.d.ts +41 -41
- package/dist/utils/flags.js +5 -3
- package/dist/utils/flags.js.map +1 -1
- package/dist/utils/gatsby-cloud-config.d.ts +4 -4
- package/dist/utils/gatsby-dependents.d.ts +8 -8
- package/dist/utils/gatsby-webpack-eslint-graphql-schema-reload-plugin.d.ts +8 -8
- package/dist/utils/gatsby-webpack-stats-extractor.d.ts +6 -6
- package/dist/utils/gatsby-webpack-virtual-modules.d.ts +6 -6
- package/dist/utils/get-cache.d.ts +2 -2
- package/dist/utils/get-latest-apis.d.ts +6 -6
- package/dist/utils/get-page-data.d.ts +3 -3
- package/dist/utils/get-public-path.d.ts +5 -5
- package/dist/utils/get-server-data.d.ts +19 -19
- package/dist/utils/get-ssl-cert.d.ts +9 -9
- package/dist/utils/get-static-dir.d.ts +12 -12
- package/dist/utils/get-value-at.d.ts +1 -1
- package/dist/utils/graphql-typegen/file-writes.d.ts +5 -5
- package/dist/utils/graphql-typegen/ts-codegen.d.ts +3 -3
- package/dist/utils/graphql-typegen/ts-codegen.js +4 -6
- package/dist/utils/graphql-typegen/ts-codegen.js.map +1 -1
- package/dist/utils/graphql-typegen/utils.d.ts +10 -10
- package/dist/utils/handle-flags.d.ts +8 -8
- package/dist/utils/is-32-bit-integer.d.ts +1 -1
- package/dist/utils/jobs/manager.d.ts +34 -34
- package/dist/utils/jobs/types.d.ts +63 -63
- package/dist/utils/jobs/worker-messaging.d.ts +10 -10
- package/dist/utils/js-chunk-names.d.ts +1 -1
- package/dist/utils/loading-indicator.d.ts +3 -3
- package/dist/utils/local-eslint-config-finder.d.ts +1 -1
- package/dist/utils/merge-gatsby-config.d.ts +27 -27
- package/dist/utils/mett.d.ts +10 -10
- package/dist/utils/module-resolver.d.ts +3 -3
- package/dist/utils/node-manifest.d.ts +45 -45
- package/dist/utils/nodes.d.ts +13 -13
- package/dist/utils/normalize-path.d.ts +2 -2
- package/dist/utils/page-data-helpers.d.ts +14 -14
- package/dist/utils/page-data.d.ts +19 -19
- package/dist/utils/page-mode.d.ts +18 -18
- package/dist/utils/page-ssr-module/bundle-webpack.d.ts +17 -17
- package/dist/utils/page-ssr-module/entry.d.ts +43 -43
- package/dist/utils/parcel/compile-gatsby-files.d.ts +18 -18
- package/dist/utils/path.d.ts +5 -5
- package/dist/utils/prepare-regex.d.ts +1 -1
- package/dist/utils/prepare-urls.d.ts +7 -7
- package/dist/utils/print-instructions.d.ts +2 -2
- package/dist/utils/reach-router-add-basecontext-export-loader.d.ts +1 -1
- package/dist/utils/report-once.d.ts +1 -1
- package/dist/utils/require-gatsby-plugin.d.ts +9 -9
- package/dist/utils/restarting-screen.d.ts +2 -2
- package/dist/utils/sample-site-for-experiment.d.ts +2 -2
- package/dist/utils/show-experiment-notice.d.ts +6 -6
- package/dist/utils/source-nodes.d.ts +8 -8
- package/dist/utils/stack-trace-utils.d.ts +24 -24
- package/dist/utils/start-server.d.ts +22 -22
- package/dist/utils/state-machine-logging.d.ts +2 -2
- package/dist/utils/static-query-utils.d.ts +16 -16
- package/dist/utils/telemetry-server.d.ts +1 -1
- package/dist/utils/test-require-error.d.ts +1 -1
- package/dist/utils/tracer/index.d.ts +12 -12
- package/dist/utils/tracer/jaeger-local.d.ts +4 -4
- package/dist/utils/tracer/zipkin-local.d.ts +11 -11
- package/dist/utils/validate-engines/child.d.ts +1 -1
- package/dist/utils/validate-engines/index.d.ts +1 -1
- package/dist/utils/validate-page-component.d.ts +12 -12
- package/dist/utils/wait-until-jobs-complete.d.ts +2 -2
- package/dist/utils/webpack/bundle.d.ts +9 -9
- package/dist/utils/webpack/plugins/cache-folder-resolver.d.ts +9 -9
- package/dist/utils/webpack/plugins/corejs-resolver.d.ts +12 -12
- package/dist/utils/webpack/plugins/force-css-hmr-for-edge-cases.d.ts +22 -22
- package/dist/utils/webpack/plugins/static-query-mapper.d.ts +7 -7
- package/dist/utils/webpack/plugins/webpack-logging.d.ts +12 -12
- package/dist/utils/webpack-error-utils.d.ts +24 -24
- package/dist/utils/webpack-plugins.d.ts +46 -46
- package/dist/utils/webpack-status.d.ts +3 -3
- package/dist/utils/webpack-utils.d.ts +121 -121
- package/dist/utils/webpack-utils.js +1 -1
- package/dist/utils/webpack-utils.js.map +1 -1
- package/dist/utils/websocket-manager.d.ts +40 -40
- package/dist/utils/worker/child/index.d.ts +5 -5
- package/dist/utils/worker/child/load-config-and-plugins.d.ts +2 -2
- package/dist/utils/worker/child/queries.d.ts +7 -7
- package/dist/utils/worker/child/render-html.d.ts +21 -21
- package/dist/utils/worker/child/schema.d.ts +2 -2
- package/dist/utils/worker/child/state.d.ts +2 -2
- package/dist/utils/worker/messaging.d.ts +8 -8
- package/dist/utils/worker/pool.d.ts +10 -10
- package/dist/utils/worker/reporter.d.ts +3 -3
- package/dist/utils/worker/types.d.ts +3 -3
- package/index.d.ts +14 -3
- package/package.json +27 -22
- package/dist/utils/print-deprecation-warnings.d.ts +0 -1
- package/dist/utils/print-deprecation-warnings.js +0 -37
- package/dist/utils/print-deprecation-warnings.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,34 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
### [4.15.2](https://github.com/gatsbyjs/gatsby/commits/HEAD/packages/gatsby) (2022-06-01)
|
|
7
|
+
|
|
8
|
+
#### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- prioritize raw body parser [#35780](https://github.com/gatsbyjs/gatsby/issues/35780) [#35786](https://github.com/gatsbyjs/gatsby/issues/35786) ([9f5c107](https://github.com/gatsbyjs/gatsby/commit/9f5c10721d16ca5d2c025254cada60fb85af5a21))
|
|
11
|
+
- Make `GatsbyImageData` nullable [#35777](https://github.com/gatsbyjs/gatsby/issues/35777) [#35785](https://github.com/gatsbyjs/gatsby/issues/35785) ([e7a3e6e](https://github.com/gatsbyjs/gatsby/commit/e7a3e6ebca645bd15f668aa3c2e763d93d648ea0))
|
|
12
|
+
- correctly auto-load preview plugin [#35745](https://github.com/gatsbyjs/gatsby/issues/35745) [#35746](https://github.com/gatsbyjs/gatsby/issues/35746) ([884c554](https://github.com/gatsbyjs/gatsby/commit/884c5545b5030846d9b8fb414b2e20bab2ceb437))
|
|
13
|
+
|
|
14
|
+
#### Chores
|
|
15
|
+
|
|
16
|
+
- re-pin select packages after 'lerna version' [#35725](https://github.com/gatsbyjs/gatsby/issues/35725) [#35726](https://github.com/gatsbyjs/gatsby/issues/35726) ([04f9509](https://github.com/gatsbyjs/gatsby/commit/04f9509ce6295215b87b377855460873e0b5afeb))
|
|
17
|
+
|
|
18
|
+
### [4.15.1](https://github.com/gatsbyjs/gatsby/commits/HEAD/packages/gatsby) (2022-05-25)
|
|
19
|
+
|
|
20
|
+
#### Bug Fixes
|
|
21
|
+
|
|
22
|
+
- correctly auto-load preview plugin [#35745](https://github.com/gatsbyjs/gatsby/issues/35745) [#35746](https://github.com/gatsbyjs/gatsby/issues/35746) ([884c554](https://github.com/gatsbyjs/gatsby/commit/884c5545b5030846d9b8fb414b2e20bab2ceb437))
|
|
23
|
+
|
|
24
|
+
#### Chores
|
|
25
|
+
|
|
26
|
+
- re-pin select packages after 'lerna version' [#35725](https://github.com/gatsbyjs/gatsby/issues/35725) [#35726](https://github.com/gatsbyjs/gatsby/issues/35726) ([04f9509](https://github.com/gatsbyjs/gatsby/commit/04f9509ce6295215b87b377855460873e0b5afeb))
|
|
27
|
+
|
|
28
|
+
### [4.14.1](https://github.com/gatsbyjs/gatsby/commits/gatsby@4.14.1/packages/gatsby) (2022-05-16)
|
|
29
|
+
|
|
30
|
+
#### Chores
|
|
31
|
+
|
|
32
|
+
- bump glob to 7.2.3 [#35666](https://github.com/gatsbyjs/gatsby/issues/35666) [#35671](https://github.com/gatsbyjs/gatsby/issues/35671) ([59165a7](https://github.com/gatsbyjs/gatsby/commit/59165a7d2421ec79525393f1e5361d204806b1ef))
|
|
33
|
+
|
|
6
34
|
## [4.14.0](https://github.com/gatsbyjs/gatsby/commits/gatsby@4.14.0/packages/gatsby) (2022-05-10)
|
|
7
35
|
|
|
8
36
|
[🧾 Release notes](https://www.gatsbyjs.com/docs/reference/release-notes/v4.14)
|
package/apis.json
CHANGED
|
@@ -3,6 +3,20 @@
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
4
|
|
|
5
5
|
exports.__esModule = true;
|
|
6
|
+
var _exportNames = {
|
|
7
|
+
graphql: true,
|
|
8
|
+
StaticQueryContext: true,
|
|
9
|
+
StaticQuery: true,
|
|
10
|
+
useStaticQuery: true,
|
|
11
|
+
prefetchPathname: true,
|
|
12
|
+
Link: true,
|
|
13
|
+
withPrefix: true,
|
|
14
|
+
withAssetPrefix: true,
|
|
15
|
+
navigate: true,
|
|
16
|
+
parsePath: true,
|
|
17
|
+
useScrollRestoration: true,
|
|
18
|
+
PageRenderer: true
|
|
19
|
+
};
|
|
6
20
|
exports.graphql = graphql;
|
|
7
21
|
exports.prefetchPathname = exports.useStaticQuery = exports.StaticQuery = exports.StaticQueryContext = void 0;
|
|
8
22
|
|
|
@@ -28,6 +42,15 @@ exports.PageRenderer = _publicPageRenderer.default;
|
|
|
28
42
|
|
|
29
43
|
var _loader = _interopRequireDefault(require("./loader"));
|
|
30
44
|
|
|
45
|
+
var _gatsbyScript = require("gatsby-script");
|
|
46
|
+
|
|
47
|
+
Object.keys(_gatsbyScript).forEach(function (key) {
|
|
48
|
+
if (key === "default" || key === "__esModule") return;
|
|
49
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
50
|
+
if (key in exports && exports[key] === _gatsbyScript[key]) return;
|
|
51
|
+
exports[key] = _gatsbyScript[key];
|
|
52
|
+
});
|
|
53
|
+
|
|
31
54
|
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); }
|
|
32
55
|
|
|
33
56
|
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; }
|
package/cli.js
CHANGED
|
File without changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const resolveModuleExports: (input: unknown) => Array<string> | undefined;
|
|
1
|
+
export declare const resolveModuleExports: (input: unknown) => Array<string> | undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { Span } from "opentracing";
|
|
2
|
-
import { ExecutionResult, Source } from "graphql";
|
|
3
|
-
import { Store } from "redux";
|
|
4
|
-
import { Reporter } from "../..";
|
|
5
|
-
import { IGatsbyState } from "../redux/types";
|
|
6
|
-
export declare type Runner = (query: string | Source, context: Record<string, any>) => Promise<ExecutionResult>;
|
|
7
|
-
export declare const createGraphQLRunner: (store: Store<IGatsbyState>, reporter: Reporter, { parentSpan, graphqlTracing, }?: {
|
|
8
|
-
parentSpan: Span | undefined;
|
|
9
|
-
graphqlTracing?: boolean | undefined;
|
|
10
|
-
}) => Runner;
|
|
1
|
+
import { Span } from "opentracing";
|
|
2
|
+
import { ExecutionResult, Source } from "graphql";
|
|
3
|
+
import { Store } from "redux";
|
|
4
|
+
import { Reporter } from "../..";
|
|
5
|
+
import { IGatsbyState } from "../redux/types";
|
|
6
|
+
export declare type Runner = (query: string | Source, context: Record<string, any>) => Promise<ExecutionResult>;
|
|
7
|
+
export declare const createGraphQLRunner: (store: Store<IGatsbyState>, reporter: Reporter, { parentSpan, graphqlTracing, }?: {
|
|
8
|
+
parentSpan: Span | undefined;
|
|
9
|
+
graphqlTracing?: boolean | undefined;
|
|
10
|
+
}) => Runner;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare function getConfigFile(siteDirectory: string, configName: string, distance?: number): Promise<{
|
|
2
|
-
configModule: any;
|
|
3
|
-
configFilePath: string;
|
|
4
|
-
}>;
|
|
1
|
+
export declare function getConfigFile(siteDirectory: string, configName: string, distance?: number): Promise<{
|
|
2
|
+
configModule: any;
|
|
3
|
+
configFilePath: string;
|
|
4
|
+
}>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { IBuildContext } from "../services";
|
|
2
|
-
import { Runner } from "./create-graphql-runner";
|
|
3
|
-
import type { GatsbyWorkerPool } from "../utils/worker/pool";
|
|
4
|
-
import { IProgram } from "../commands/types";
|
|
5
|
-
export declare function bootstrap(initialContext: Partial<IBuildContext> & {
|
|
6
|
-
program: IProgram;
|
|
7
|
-
}): Promise<{
|
|
8
|
-
gatsbyNodeGraphQLFunction: Runner;
|
|
9
|
-
workerPool: GatsbyWorkerPool;
|
|
10
|
-
}>;
|
|
1
|
+
import { IBuildContext } from "../services";
|
|
2
|
+
import { Runner } from "./create-graphql-runner";
|
|
3
|
+
import type { GatsbyWorkerPool } from "../utils/worker/pool";
|
|
4
|
+
import { IProgram } from "../commands/types";
|
|
5
|
+
export declare function bootstrap(initialContext: Partial<IBuildContext> & {
|
|
6
|
+
program: IProgram;
|
|
7
|
+
}): Promise<{
|
|
8
|
+
gatsbyNodeGraphQLFunction: Runner;
|
|
9
|
+
workerPool: GatsbyWorkerPool;
|
|
10
|
+
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { IProgram } from "../../commands/types";
|
|
2
|
-
import { IGatsbyConfig } from "../../internal";
|
|
3
|
-
export declare function loadConfig({ siteDirectory, processFlags, }: {
|
|
4
|
-
siteDirectory: string;
|
|
5
|
-
processFlags?: boolean;
|
|
6
|
-
program?: IProgram;
|
|
7
|
-
}): Promise<IGatsbyConfig>;
|
|
1
|
+
import { IProgram } from "../../commands/types";
|
|
2
|
+
import { IGatsbyConfig } from "../../internal";
|
|
3
|
+
export declare function loadConfig({ siteDirectory, processFlags, }: {
|
|
4
|
+
siteDirectory: string;
|
|
5
|
+
processFlags?: boolean;
|
|
6
|
+
program?: IProgram;
|
|
7
|
+
}): Promise<IGatsbyConfig>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { IFlattenedPlugin } from "./types";
|
|
2
|
-
import { IGatsbyConfig } from "../../internal";
|
|
3
|
-
export declare function loadPlugins(rawConfig: IGatsbyConfig, rootDir: string): Promise<Array<IFlattenedPlugin>>;
|
|
1
|
+
import { IFlattenedPlugin } from "./types";
|
|
2
|
+
import { IGatsbyConfig } from "../../internal";
|
|
3
|
+
export declare function loadPlugins(rawConfig: IGatsbyConfig, rootDir: string): Promise<Array<IFlattenedPlugin>>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { IPluginInfo, ISiteConfig } from "./types";
|
|
2
|
-
export declare function loadInternalPlugins(config: ISiteConfig | undefined, rootDir: string): Array<IPluginInfo>;
|
|
1
|
+
import { IPluginInfo, ISiteConfig } from "./types";
|
|
2
|
+
export declare function loadInternalPlugins(config: ISiteConfig | undefined, rootDir: string): Array<IPluginInfo>;
|
|
@@ -120,7 +120,11 @@ function loadInternalPlugins(config = {}, rootDir) {
|
|
|
120
120
|
resolve: require.resolve(`gatsby-plugin-page-creator`),
|
|
121
121
|
options: pageCreatorOptions
|
|
122
122
|
}, rootDir);
|
|
123
|
-
plugins.push(processedPageCreatorPlugin);
|
|
123
|
+
plugins.push(processedPageCreatorPlugin); // Partytown plugin collects usage of <Script strategy={"off-main-thread"} />
|
|
124
|
+
// in `wrapRootElement`, so we have to make sure it's the last one running to be able to
|
|
125
|
+
// collect scripts that users might inject in their `wrapRootElement`
|
|
126
|
+
|
|
127
|
+
plugins.push((0, _processPlugin.processPlugin)(_path.default.join(__dirname, `../../internal-plugins/partytown`), rootDir));
|
|
124
128
|
return plugins;
|
|
125
129
|
}
|
|
126
130
|
//# sourceMappingURL=load-internal-plugins.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/bootstrap/load-plugins/load-internal-plugins.ts"],"names":["TYPESCRIPT_PLUGIN_NAME","loadInternalPlugins","config","rootDir","plugins","configuredPluginNames","Set","internalPlugins","filter","Boolean","forEach","relPath","absPath","path","join","__dirname","push","plugin","processedPlugin","add","name","resolve","require","options","pathCheck","has","GATSBY_CLOUD_PLUGIN_NAME","reporter","panic","process","env","GATSBY_CLOUD","GATSBY_PLUGIN_PREVIEW_NAME","processedTypeScriptPlugin","allExtensions","isTSX","jsxPragma","cwd","id","version","pluginOptions","program","store","getState","pageCreatorOptions","directory","pageCreatorPlugin","find","processedPageCreatorPlugin"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AAOA;;AACA;;AACA;;AACA;;AAOA;;AAEA,MAAMA,sBAAsB,GAAI,0BAAhC;;AAEO,SAASC,mBAAT,CACLC,MAAmB,GAAG,EADjB,EAELC,OAFK,EAGe;AACpB;AACA,QAAMC,OAA2B,GAAG,EAApC;AACA,QAAMC,qBAAqB,GAAG,IAAIC,GAAJ,EAA9B,CAHoB,CAKpB;;AACA,QAAMC,eAAe,GAAG,CACrB,qCADqB,EAErB,0CAFqB,EAGrB,6CAHqB,EAIrB,qCAJqB,EAKrB,0DALqB,EAMrB,6CANqB,EAOrB,kCAPqB,EAQtBC,MARsB,CAQfC,OARe,CAAxB;AAUAF,EAAAA,eAAe,CAACG,OAAhB,CAAwBC,OAAO,IAAI;AACjC,UAAMC,OAAO,GAAGC,cAAKC,IAAL,CAAUC,SAAV,EAAqBJ,OAArB,CAAhB;;AACAP,IAAAA,OAAO,CAACY,IAAR,CAAa,kCAAcJ,OAAd,EAAuBT,OAAvB,CAAb;AACD,GAHD,EAhBoB,CAqBpB;;AACA,MAAID,MAAM,CAACE,OAAX,EAAoB;AAClBF,IAAAA,MAAM,CAACE,OAAP,CAAeM,OAAf,CAAuBO,MAAM,IAAI;AAC/B,YAAMC,eAAe,GAA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BN,MAAM,CAACM,OAAP,CAAeV,IAAlC,IAA4C,EAAlD,MACE,4BAAMA,cAAKC,IAAL,CAAU2B,OAAO,CAACI,SAAlB,EAA8B,WAA9B,CAAN,CALoB,CAA1B;;AAOA,QAAIC,iBAAJ,EAAuB;AACrB;AACAF,MAAAA,kBAAkB,GAAGE,iBAAiB,CAACvB,OAAvC;AACD;AACF;;AAED,QAAMyB,0BAA0B,GAAG,kCACjC;AACE3B,IAAAA,OAAO,EAAEC,OAAO,CAACD,OAAR,CAAiB,4BAAjB,CADX;AAEEE,IAAAA,OAAO,EAAEqB;AAFX,GADiC,EAKjCzC,OALiC,CAAnC;AAQAC,EAAAA,OAAO,CAACY,IAAR,CAAagC,0BAAb;
|
|
1
|
+
{"version":3,"sources":["../../../src/bootstrap/load-plugins/load-internal-plugins.ts"],"names":["TYPESCRIPT_PLUGIN_NAME","loadInternalPlugins","config","rootDir","plugins","configuredPluginNames","Set","internalPlugins","filter","Boolean","forEach","relPath","absPath","path","join","__dirname","push","plugin","processedPlugin","add","name","resolve","require","options","pathCheck","has","GATSBY_CLOUD_PLUGIN_NAME","reporter","panic","process","env","GATSBY_CLOUD","GATSBY_PLUGIN_PREVIEW_NAME","processedTypeScriptPlugin","allExtensions","isTSX","jsxPragma","cwd","id","version","pluginOptions","program","store","getState","pageCreatorOptions","directory","pageCreatorPlugin","find","processedPageCreatorPlugin"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AAOA;;AACA;;AACA;;AACA;;AAOA;;AAEA,MAAMA,sBAAsB,GAAI,0BAAhC;;AAEO,SAASC,mBAAT,CACLC,MAAmB,GAAG,EADjB,EAELC,OAFK,EAGe;AACpB;AACA,QAAMC,OAA2B,GAAG,EAApC;AACA,QAAMC,qBAAqB,GAAG,IAAIC,GAAJ,EAA9B,CAHoB,CAKpB;;AACA,QAAMC,eAAe,GAAG,CACrB,qCADqB,EAErB,0CAFqB,EAGrB,6CAHqB,EAIrB,qCAJqB,EAKrB,0DALqB,E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jC,CAxGoB,CA0GpB;;;AACA,MAAIG,kBAAiD,GAAG;AACtD/B,IAAAA,IAAI,EAAE,4BAAMA,cAAKC,IAAL,CAAU2B,OAAO,CAACI,SAAlB,EAA8B,WAA9B,CAAN,CADgD;AAEtDrB,IAAAA,SAAS,EAAE;AAF2C,GAAxD;;AAKA,MAAItB,MAAM,CAACE,OAAX,EAAoB;AAClB,UAAM0C,iBAAiB,GAAG5C,MAAM,CAACE,OAAP,CAAe2C,IAAf,CACvB9B,MAAD,IACE,OAAOA,MAAP,KAAmB,QAAnB,IACAA,MAAM,CAACI,OAAP,KAAoB,4BADpB,IAEA,4BAAOJ,MAAM,CAACM,OAAP,IAAkBN,MAAM,CAACM,OAAP,CAAeV,IAAlC,IAA4C,EAAlD,MACE,4BAAMA,cAAKC,IAAL,CAAU2B,OAAO,CAACI,SAAlB,EAA8B,WAA9B,CAAN,CALoB,CAA1B;;AAOA,QAAIC,iBAAJ,EAAuB;AACrB;AACAF,MAAAA,kBAAkB,GAAGE,iBAAiB,CAACvB,OAAvC;AACD;AACF;;AAED,QAAMyB,0BAA0B,GAAG,kCACjC;AACE3B,IAAAA,OAAO,EAAEC,OAAO,CAACD,OAAR,CAAiB,4BAAjB,CADX;AAEEE,IAAAA,OAAO,EAAEqB;AAFX,GADiC,EAKjCzC,OALiC,CAAnC;AAQAC,EAAAA,OAAO,CAACY,IAAR,CAAagC,0BAAb,EAtIoB,CAwIpB;AACA;AACA;;AACA5C,EAAAA,OAAO,CAACY,IAAR,CACE,kCACEH,cAAKC,IAAL,CAAUC,SAAV,EAAsB,kCAAtB,CADF,EAEEZ,OAFF,CADF;AAOA,SAAOC,OAAP;AACD","sourcesContent":["import { slash } from \"gatsby-core-utils\"\nimport path from \"path\"\nimport reporter from \"gatsby-cli/lib/reporter\"\nimport { store } from \"../../redux\"\nimport {\n IPluginInfo,\n IPluginRefObject,\n IPluginRefOptions,\n ISiteConfig,\n} from \"./types\"\nimport { processPlugin } from \"./process-plugin\"\nimport { createPluginId } from \"./utils/create-id\"\nimport { createFileContentHash } from \"./utils/create-hash\"\nimport {\n addGatsbyPluginCloudPluginWhenInstalled,\n addGatsbyPluginPreviewWhenInstalled,\n incompatibleGatsbyCloudPlugin,\n GATSBY_CLOUD_PLUGIN_NAME,\n GATSBY_PLUGIN_PREVIEW_NAME,\n} from \"./utils/handle-gatsby-cloud\"\nimport { getResolvedFieldsForPlugin } from \"../../utils/parcel/compile-gatsby-files\"\n\nconst TYPESCRIPT_PLUGIN_NAME = `gatsby-plugin-typescript`\n\nexport function loadInternalPlugins(\n config: ISiteConfig = {},\n rootDir: string\n): Array<IPluginInfo> {\n // Instantiate plugins.\n const plugins: Array<IPluginInfo> = []\n const configuredPluginNames = new Set()\n\n // Add internal plugins\n const internalPlugins = [\n `../../internal-plugins/dev-404-page`,\n `../../internal-plugins/load-babel-config`,\n `../../internal-plugins/internal-data-bridge`,\n `../../internal-plugins/prod-404-500`,\n `../../internal-plugins/webpack-theme-component-shadowing`,\n `../../internal-plugins/bundle-optimisations`,\n `../../internal-plugins/functions`,\n ].filter(Boolean) as Array<string>\n\n internalPlugins.forEach(relPath => {\n const absPath = path.join(__dirname, relPath)\n plugins.push(processPlugin(absPath, rootDir))\n })\n\n // Add plugins from the site config.\n if (config.plugins) {\n config.plugins.forEach(plugin => {\n const processedPlugin = processPlugin(plugin, rootDir)\n plugins.push(processedPlugin)\n configuredPluginNames.add(processedPlugin.name)\n })\n }\n\n // the order of all of these page-creators matters. The \"last plugin wins\",\n // so the user's site comes last, and each page-creator instance has to\n // match the plugin definition order before that. This works fine for themes\n // because themes have already been added in the proper order to the plugins\n // array\n plugins.forEach(plugin => {\n plugins.push(\n processPlugin(\n {\n resolve: require.resolve(`gatsby-plugin-page-creator`),\n options: {\n path: slash(path.join(plugin.resolve, `src/pages`)),\n pathCheck: false,\n },\n },\n rootDir\n )\n )\n })\n\n if (\n _CFLAGS_.GATSBY_MAJOR === `4` &&\n configuredPluginNames.has(GATSBY_CLOUD_PLUGIN_NAME) &&\n incompatibleGatsbyCloudPlugin(plugins)\n ) {\n reporter.panic(\n `Plugin gatsby-plugin-gatsby-cloud is not compatible with your gatsby version. Please upgrade to gatsby-plugin-gatsby-cloud@next`\n )\n }\n\n if (\n !configuredPluginNames.has(GATSBY_CLOUD_PLUGIN_NAME) &&\n (process.env.GATSBY_CLOUD === `true` || process.env.GATSBY_CLOUD === `1`)\n ) {\n addGatsbyPluginCloudPluginWhenInstalled(plugins, rootDir)\n }\n\n if (\n !configuredPluginNames.has(GATSBY_PLUGIN_PREVIEW_NAME) &&\n (process.env.GATSBY_CLOUD === `true` || process.env.GATSBY_CLOUD === `1`)\n ) {\n addGatsbyPluginPreviewWhenInstalled(plugins, rootDir)\n }\n\n // Support Typescript by default but allow users to override it\n if (!configuredPluginNames.has(TYPESCRIPT_PLUGIN_NAME)) {\n const processedTypeScriptPlugin = processPlugin(\n {\n resolve: require.resolve(TYPESCRIPT_PLUGIN_NAME),\n options: {\n // TODO(@mxstbr): Do not hard-code these defaults but infer them from the\n // pluginOptionsSchema of gatsby-plugin-typescript\n allExtensions: false,\n isTSX: false,\n jsxPragma: `React`,\n },\n },\n rootDir\n )\n plugins.push(processedTypeScriptPlugin)\n }\n\n // Add the site's default \"plugin\" i.e. gatsby-x files in root of site.\n plugins.push({\n resolve: slash(process.cwd()),\n id: createPluginId(`default-site-plugin`),\n name: `default-site-plugin`,\n version: createFileContentHash(process.cwd(), `gatsby-*`),\n pluginOptions: {\n plugins: [],\n },\n ...getResolvedFieldsForPlugin(rootDir, `default-site-plugin`),\n })\n\n const program = store.getState().program\n\n // default options for gatsby-plugin-page-creator\n let pageCreatorOptions: IPluginRefOptions | undefined = {\n path: slash(path.join(program.directory, `src/pages`)),\n pathCheck: false,\n }\n\n if (config.plugins) {\n const pageCreatorPlugin = config.plugins.find(\n (plugin): plugin is IPluginRefObject =>\n typeof plugin !== `string` &&\n plugin.resolve === `gatsby-plugin-page-creator` &&\n slash((plugin.options && plugin.options.path) || ``) ===\n slash(path.join(program.directory, `src/pages`))\n )\n if (pageCreatorPlugin) {\n // override the options if there are any user specified options\n pageCreatorOptions = pageCreatorPlugin.options\n }\n }\n\n const processedPageCreatorPlugin = processPlugin(\n {\n resolve: require.resolve(`gatsby-plugin-page-creator`),\n options: pageCreatorOptions,\n },\n rootDir\n )\n\n plugins.push(processedPageCreatorPlugin)\n\n // Partytown plugin collects usage of <Script strategy={\"off-main-thread\"} />\n // in `wrapRootElement`, so we have to make sure it's the last one running to be able to\n // collect scripts that users might inject in their `wrapRootElement`\n plugins.push(\n processPlugin(\n path.join(__dirname, `../../internal-plugins/partytown`),\n rootDir\n )\n )\n\n return plugins\n}\n"],"file":"load-internal-plugins.js"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { IPluginInfo, PluginRef } from "./types";
|
|
2
|
-
export declare function processPlugin(plugin: PluginRef, rootDir: string): IPluginInfo;
|
|
1
|
+
import { IPluginInfo, PluginRef } from "./types";
|
|
2
|
+
export declare function processPlugin(plugin: PluginRef, rootDir: string): IPluginInfo;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { IPluginInfo, PluginRef } from "./types";
|
|
2
|
-
/**
|
|
3
|
-
* @param plugin
|
|
4
|
-
* This should be a plugin spec object where possible but can also be the
|
|
5
|
-
* name of a plugin.
|
|
6
|
-
*
|
|
7
|
-
* When it is a name, it can be a name of a local plugin, the name of a plugin
|
|
8
|
-
* located in node_modules, or a Gatsby internal plugin. In the last case the
|
|
9
|
-
* plugin will be an absolute path.
|
|
10
|
-
* @param rootDir
|
|
11
|
-
* This is the project location, from which are found the plugins
|
|
12
|
-
*/
|
|
13
|
-
export declare function resolvePlugin(plugin: PluginRef, rootDir: string): IPluginInfo;
|
|
1
|
+
import { IPluginInfo, PluginRef } from "./types";
|
|
2
|
+
/**
|
|
3
|
+
* @param plugin
|
|
4
|
+
* This should be a plugin spec object where possible but can also be the
|
|
5
|
+
* name of a plugin.
|
|
6
|
+
*
|
|
7
|
+
* When it is a name, it can be a name of a local plugin, the name of a plugin
|
|
8
|
+
* located in node_modules, or a Gatsby internal plugin. In the last case the
|
|
9
|
+
* plugin will be an absolute path.
|
|
10
|
+
* @param rootDir
|
|
11
|
+
* This is the project location, from which are found the plugins
|
|
12
|
+
*/
|
|
13
|
+
export declare function resolvePlugin(plugin: PluginRef, rootDir: string): IPluginInfo;
|
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
export interface IRawSiteConfig {
|
|
2
|
-
plugins?: Array<PluginRef>;
|
|
3
|
-
}
|
|
4
|
-
export interface ISiteConfig extends IRawSiteConfig {
|
|
5
|
-
plugins?: Array<IPluginRefObject>;
|
|
6
|
-
}
|
|
7
|
-
export interface IPluginInfo {
|
|
8
|
-
/** Unique ID describing a plugin */
|
|
9
|
-
id: string;
|
|
10
|
-
/** The absolute path to the plugin */
|
|
11
|
-
resolve: string;
|
|
12
|
-
/** The absolute path to the compiled plugin's gatsby-node module, if there is one */
|
|
13
|
-
resolvedCompiledGatsbyNode?: string;
|
|
14
|
-
/** The plugin name */
|
|
15
|
-
name: string;
|
|
16
|
-
/** The plugin version (can be content hash) */
|
|
17
|
-
version: string;
|
|
18
|
-
/** Options passed to the plugin */
|
|
19
|
-
pluginOptions?: IPluginInfoOptions;
|
|
20
|
-
subPluginPaths?: Array<string>;
|
|
21
|
-
module?: any;
|
|
22
|
-
modulePath?: string;
|
|
23
|
-
}
|
|
24
|
-
export interface IPluginInfoOptions {
|
|
25
|
-
plugins?: Array<IPluginInfo>;
|
|
26
|
-
path?: string;
|
|
27
|
-
[option: string]: unknown;
|
|
28
|
-
}
|
|
29
|
-
export interface IFlattenedPlugin extends IPluginInfo {
|
|
30
|
-
skipSSR?: boolean;
|
|
31
|
-
ssrAPIs: Array<string>;
|
|
32
|
-
nodeAPIs: Array<string>;
|
|
33
|
-
browserAPIs: Array<string>;
|
|
34
|
-
}
|
|
35
|
-
export interface IPluginRefObject {
|
|
36
|
-
resolve: string;
|
|
37
|
-
options?: IPluginRefOptions;
|
|
38
|
-
parentDir?: string;
|
|
39
|
-
subPluginPaths?: Array<string>;
|
|
40
|
-
module?: any;
|
|
41
|
-
modulePath?: string;
|
|
42
|
-
}
|
|
43
|
-
export declare type PluginRef = string | IPluginRefObject;
|
|
44
|
-
export interface IPluginRefOptions {
|
|
45
|
-
plugins?: Array<PluginRef>;
|
|
46
|
-
path?: string;
|
|
47
|
-
[option: string]: unknown;
|
|
48
|
-
}
|
|
1
|
+
export interface IRawSiteConfig {
|
|
2
|
+
plugins?: Array<PluginRef>;
|
|
3
|
+
}
|
|
4
|
+
export interface ISiteConfig extends IRawSiteConfig {
|
|
5
|
+
plugins?: Array<IPluginRefObject>;
|
|
6
|
+
}
|
|
7
|
+
export interface IPluginInfo {
|
|
8
|
+
/** Unique ID describing a plugin */
|
|
9
|
+
id: string;
|
|
10
|
+
/** The absolute path to the plugin */
|
|
11
|
+
resolve: string;
|
|
12
|
+
/** The absolute path to the compiled plugin's gatsby-node module, if there is one */
|
|
13
|
+
resolvedCompiledGatsbyNode?: string;
|
|
14
|
+
/** The plugin name */
|
|
15
|
+
name: string;
|
|
16
|
+
/** The plugin version (can be content hash) */
|
|
17
|
+
version: string;
|
|
18
|
+
/** Options passed to the plugin */
|
|
19
|
+
pluginOptions?: IPluginInfoOptions;
|
|
20
|
+
subPluginPaths?: Array<string>;
|
|
21
|
+
module?: any;
|
|
22
|
+
modulePath?: string;
|
|
23
|
+
}
|
|
24
|
+
export interface IPluginInfoOptions {
|
|
25
|
+
plugins?: Array<IPluginInfo>;
|
|
26
|
+
path?: string;
|
|
27
|
+
[option: string]: unknown;
|
|
28
|
+
}
|
|
29
|
+
export interface IFlattenedPlugin extends IPluginInfo {
|
|
30
|
+
skipSSR?: boolean;
|
|
31
|
+
ssrAPIs: Array<string>;
|
|
32
|
+
nodeAPIs: Array<string>;
|
|
33
|
+
browserAPIs: Array<string>;
|
|
34
|
+
}
|
|
35
|
+
export interface IPluginRefObject {
|
|
36
|
+
resolve: string;
|
|
37
|
+
options?: IPluginRefOptions;
|
|
38
|
+
parentDir?: string;
|
|
39
|
+
subPluginPaths?: Array<string>;
|
|
40
|
+
module?: any;
|
|
41
|
+
modulePath?: string;
|
|
42
|
+
}
|
|
43
|
+
export declare type PluginRef = string | IPluginRefObject;
|
|
44
|
+
export interface IPluginRefOptions {
|
|
45
|
+
plugins?: Array<PluginRef>;
|
|
46
|
+
path?: string;
|
|
47
|
+
[option: string]: unknown;
|
|
48
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { PluginRef } from "../types";
|
|
2
|
-
/**
|
|
3
|
-
* Checks if a plugin is a valid local plugin and returns the resolved path if it is.
|
|
4
|
-
*/
|
|
5
|
-
export declare function checkLocalPlugin(plugin: PluginRef, rootDir: string): {
|
|
6
|
-
validLocalPlugin: boolean;
|
|
7
|
-
localPluginPath?: string;
|
|
8
|
-
};
|
|
1
|
+
import { PluginRef } from "../types";
|
|
2
|
+
/**
|
|
3
|
+
* Checks if a plugin is a valid local plugin and returns the resolved path if it is.
|
|
4
|
+
*/
|
|
5
|
+
export declare function checkLocalPlugin(plugin: PluginRef, rootDir: string): {
|
|
6
|
+
validLocalPlugin: boolean;
|
|
7
|
+
localPluginPath?: string;
|
|
8
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function createFileContentHash(root: string, globPattern: string): string;
|
|
1
|
+
export declare function createFileContentHash(root: string, globPattern: string): string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { IPluginRefObject } from "../types";
|
|
2
|
-
/**
|
|
3
|
-
* Make sure key is unique to plugin options. E.g. there could
|
|
4
|
-
* be multiple source-filesystem plugins, with different names
|
|
5
|
-
* (docs, blogs).
|
|
6
|
-
*
|
|
7
|
-
* @param name Name of the plugin
|
|
8
|
-
* @param pluginObject Object of the plugin
|
|
9
|
-
*/
|
|
10
|
-
export declare const createPluginId: (name: string, pluginObject?: IPluginRefObject | null) => string;
|
|
1
|
+
import { IPluginRefObject } from "../types";
|
|
2
|
+
/**
|
|
3
|
+
* Make sure key is unique to plugin options. E.g. there could
|
|
4
|
+
* be multiple source-filesystem plugins, with different names
|
|
5
|
+
* (docs, blogs).
|
|
6
|
+
*
|
|
7
|
+
* @param name Name of the plugin
|
|
8
|
+
* @param pluginObject Object of the plugin
|
|
9
|
+
*/
|
|
10
|
+
export declare const createPluginId: (name: string, pluginObject?: IPluginRefObject | null) => string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { IPluginInfo } from "../types";
|
|
2
|
-
export declare const flattenPlugins: (plugins: Array<IPluginInfo>) => Array<IPluginInfo>;
|
|
1
|
+
import { IPluginInfo } from "../types";
|
|
2
|
+
export declare const flattenPlugins: (plugins: Array<IPluginInfo>) => Array<IPluginInfo>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { ExportType, ICurrentAPIs } from "../validate";
|
|
2
|
-
export declare const getAPI: (api: {
|
|
3
|
-
node: {
|
|
4
|
-
[api: string]: boolean;
|
|
5
|
-
};
|
|
6
|
-
browser: {
|
|
7
|
-
[api: string]: boolean;
|
|
8
|
-
};
|
|
9
|
-
ssr: {
|
|
10
|
-
[api: string]: boolean;
|
|
11
|
-
};
|
|
12
|
-
}) => ICurrentAPIs;
|
|
1
|
+
import { ExportType, ICurrentAPIs } from "../validate";
|
|
2
|
+
export declare const getAPI: (api: {
|
|
3
|
+
node: {
|
|
4
|
+
[api: string]: boolean;
|
|
5
|
+
};
|
|
6
|
+
browser: {
|
|
7
|
+
[api: string]: boolean;
|
|
8
|
+
};
|
|
9
|
+
ssr: {
|
|
10
|
+
[api: string]: boolean;
|
|
11
|
+
};
|
|
12
|
+
}) => ICurrentAPIs;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { IPluginInfo } from "../types";
|
|
2
|
-
export declare const GATSBY_CLOUD_PLUGIN_NAME = "gatsby-plugin-gatsby-cloud";
|
|
3
|
-
export declare const GATSBY_PLUGIN_PREVIEW_NAME = "@gatsby-cloud-pkg/gatsby-plugin-preview";
|
|
4
|
-
export declare function addGatsbyPluginPreviewWhenInstalled(plugins: Array<IPluginInfo>, rootDir: string): void;
|
|
5
|
-
export declare function addGatsbyPluginCloudPluginWhenInstalled(plugins: Array<IPluginInfo>, rootDir: string): void;
|
|
6
|
-
export declare function incompatibleGatsbyCloudPlugin(plugins: Array<IPluginInfo>): boolean;
|
|
1
|
+
import { IPluginInfo } from "../types";
|
|
2
|
+
export declare const GATSBY_CLOUD_PLUGIN_NAME = "gatsby-plugin-gatsby-cloud";
|
|
3
|
+
export declare const GATSBY_PLUGIN_PREVIEW_NAME = "@gatsby-cloud-pkg/gatsby-plugin-preview";
|
|
4
|
+
export declare function addGatsbyPluginPreviewWhenInstalled(plugins: Array<IPluginInfo>, rootDir: string): void;
|
|
5
|
+
export declare function addGatsbyPluginCloudPluginWhenInstalled(plugins: Array<IPluginInfo>, rootDir: string): void;
|
|
6
|
+
export declare function incompatibleGatsbyCloudPlugin(plugins: Array<IPluginInfo>): boolean;
|
|
@@ -26,7 +26,7 @@ function addCloudPluginWhenInstalled(plugins, rootDir, name) {
|
|
|
26
26
|
|
|
27
27
|
if (cloudPluginLocation) {
|
|
28
28
|
const processedGatsbyCloudPlugin = (0, _processPlugin.processPlugin)({
|
|
29
|
-
resolve:
|
|
29
|
+
resolve: name,
|
|
30
30
|
options: {}
|
|
31
31
|
}, rootDir);
|
|
32
32
|
plugins.push(processedGatsbyCloudPlugin);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/bootstrap/load-plugins/utils/handle-gatsby-cloud.ts"],"names":["GATSBY_CLOUD_PLUGIN_NAME","GATSBY_PLUGIN_PREVIEW_NAME","addCloudPluginWhenInstalled","plugins","rootDir","name","cloudPluginLocation","processedGatsbyCloudPlugin","resolve","options","push","addGatsbyPluginPreviewWhenInstalled","addGatsbyPluginCloudPluginWhenInstalled","incompatibleGatsbyCloudPlugin","plugin","find","semver","satisfies","version","includePrerelease"],"mappings":";;;;;;;;AAAA;;AACA;;AAEA;;;;;;AAEO,MAAMA,wBAAwB,GAAI,4BAAlC;;AACA,MAAMC,0BAA0B,GAAI,yCAApC;;;AAEP,SAASC,2BAAT,CACEC,OADF,EAEEC,OAFF,EAGEC,IAHF,EAIQ;AACN,QAAMC,mBAAmB,GAAG,yBAAkBF,OAAlB,EAA2BC,IAA3B,CAA5B;;AAEA,MAAIC,mBAAJ,EAAyB;AACvB,UAAMC,0BAA0B,GAAG,kCACjC;AACEC,MAAAA,OAAO,
|
|
1
|
+
{"version":3,"sources":["../../../../src/bootstrap/load-plugins/utils/handle-gatsby-cloud.ts"],"names":["GATSBY_CLOUD_PLUGIN_NAME","GATSBY_PLUGIN_PREVIEW_NAME","addCloudPluginWhenInstalled","plugins","rootDir","name","cloudPluginLocation","processedGatsbyCloudPlugin","resolve","options","push","addGatsbyPluginPreviewWhenInstalled","addGatsbyPluginCloudPluginWhenInstalled","incompatibleGatsbyCloudPlugin","plugin","find","semver","satisfies","version","includePrerelease"],"mappings":";;;;;;;;AAAA;;AACA;;AAEA;;;;;;AAEO,MAAMA,wBAAwB,GAAI,4BAAlC;;AACA,MAAMC,0BAA0B,GAAI,yCAApC;;;AAEP,SAASC,2BAAT,CACEC,OADF,EAEEC,OAFF,EAGEC,IAHF,EAIQ;AACN,QAAMC,mBAAmB,GAAG,yBAAkBF,OAAlB,EAA2BC,IAA3B,CAA5B;;AAEA,MAAIC,mBAAJ,EAAyB;AACvB,UAAMC,0BAA0B,GAAG,kCACjC;AACEC,MAAAA,OAAO,EAAEH,IADX;AAEEI,MAAAA,OAAO,EAAE;AAFX,KADiC,EAKjCL,OALiC,CAAnC;AAOAD,IAAAA,OAAO,CAACO,IAAR,CAAaH,0BAAb;AACD;AACF;;AAEM,SAASI,mCAAT,CACLR,OADK,EAELC,OAFK,EAGC;AACNF,EAAAA,2BAA2B,CAACC,OAAD,EAAUC,OAAV,EAAmBH,0BAAnB,CAA3B;AACD;;AAEM,SAASW,uCAAT,CACLT,OADK,EAELC,OAFK,EAGC;AACNF,EAAAA,2BAA2B,CAACC,OAAD,EAAUC,OAAV,EAAmBJ,wBAAnB,CAA3B;AACD;;AAEM,SAASa,6BAAT,CACLV,OADK,EAEI;AACT,QAAMW,MAAM,GAAGX,OAAO,CAACY,IAAR,CACbD,MAAM,IAAIA,MAAM,CAACT,IAAP,KAAgBL,wBADb,CAAf;AAIA,SAAO,CAACgB,MAAM,CAACC,SAAP,CAAiBH,MAAM,CAAEI,OAAzB,EAAmC,eAAnC,EAAmD;AACzDC,IAAAA,iBAAiB,EAAE;AADsC,GAAnD,CAAR;AAGD","sourcesContent":["import { silent as resolveFromSilent } from \"resolve-from\"\nimport * as semver from \"semver\"\nimport { IPluginInfo } from \"../types\"\nimport { processPlugin } from \"../process-plugin\"\n\nexport const GATSBY_CLOUD_PLUGIN_NAME = `gatsby-plugin-gatsby-cloud`\nexport const GATSBY_PLUGIN_PREVIEW_NAME = `@gatsby-cloud-pkg/gatsby-plugin-preview`\n\nfunction addCloudPluginWhenInstalled(\n plugins: Array<IPluginInfo>,\n rootDir: string,\n name: string\n): void {\n const cloudPluginLocation = resolveFromSilent(rootDir, name)\n\n if (cloudPluginLocation) {\n const processedGatsbyCloudPlugin = processPlugin(\n {\n resolve: name,\n options: {},\n },\n rootDir\n )\n plugins.push(processedGatsbyCloudPlugin)\n }\n}\n\nexport function addGatsbyPluginPreviewWhenInstalled(\n plugins: Array<IPluginInfo>,\n rootDir: string\n): void {\n addCloudPluginWhenInstalled(plugins, rootDir, GATSBY_PLUGIN_PREVIEW_NAME)\n}\n\nexport function addGatsbyPluginCloudPluginWhenInstalled(\n plugins: Array<IPluginInfo>,\n rootDir: string\n): void {\n addCloudPluginWhenInstalled(plugins, rootDir, GATSBY_CLOUD_PLUGIN_NAME)\n}\n\nexport function incompatibleGatsbyCloudPlugin(\n plugins: Array<IPluginInfo>\n): boolean {\n const plugin = plugins.find(\n plugin => plugin.name === GATSBY_CLOUD_PLUGIN_NAME\n )\n\n return !semver.satisfies(plugin!.version, `>=4.0.0-alpha`, {\n includePrerelease: true,\n })\n}\n"],"file":"handle-gatsby-cloud.js"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ISiteConfig, IRawSiteConfig } from "../types";
|
|
2
|
-
import { IPluginRefObject, PluginRef } from "gatsby-plugin-utils/dist/types";
|
|
3
|
-
export declare function normalizePlugin(plugin: IPluginRefObject | string): IPluginRefObject;
|
|
4
|
-
export declare function normalizePlugins(plugins?: Array<PluginRef>): Array<IPluginRefObject>;
|
|
5
|
-
export declare const normalizeConfig: (config?: IRawSiteConfig) => ISiteConfig;
|
|
1
|
+
import { ISiteConfig, IRawSiteConfig } from "../types";
|
|
2
|
+
import { IPluginRefObject, PluginRef } from "gatsby-plugin-utils/dist/types";
|
|
3
|
+
export declare function normalizePlugin(plugin: IPluginRefObject | string): IPluginRefObject;
|
|
4
|
+
export declare function normalizePlugins(plugins?: Array<PluginRef>): Array<IPluginRefObject>;
|
|
5
|
+
export declare const normalizeConfig: (config?: IRawSiteConfig) => ISiteConfig;
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { PackageJson } from "../../../";
|
|
2
|
-
import { IPluginInfo, IFlattenedPlugin, ISiteConfig } from "./types";
|
|
3
|
-
interface IApi {
|
|
4
|
-
version?: string;
|
|
5
|
-
}
|
|
6
|
-
export interface IEntry {
|
|
7
|
-
exportName: string;
|
|
8
|
-
pluginName: string;
|
|
9
|
-
pluginVersion: string;
|
|
10
|
-
api?: IApi;
|
|
11
|
-
}
|
|
12
|
-
export declare type ExportType = "node" | "browser" | "ssr";
|
|
13
|
-
declare type IEntryMap = {
|
|
14
|
-
[exportType in ExportType]: Array<IEntry>;
|
|
15
|
-
};
|
|
16
|
-
export declare type ICurrentAPIs = {
|
|
17
|
-
[exportType in ExportType]: Array<string>;
|
|
18
|
-
};
|
|
19
|
-
export declare function handleBadExports({ currentAPIs, badExports, }: {
|
|
20
|
-
currentAPIs: ICurrentAPIs;
|
|
21
|
-
badExports: {
|
|
22
|
-
[api in ExportType]: Array<IEntry>;
|
|
23
|
-
};
|
|
24
|
-
}): Promise<void>;
|
|
25
|
-
export declare function validateConfigPluginsOptions(config: ISiteConfig | undefined, rootDir: string): Promise<void>;
|
|
26
|
-
/**
|
|
27
|
-
* Identify which APIs each plugin exports
|
|
28
|
-
*/
|
|
29
|
-
export declare function collatePluginAPIs({ currentAPIs, flattenedPlugins, }: {
|
|
30
|
-
currentAPIs: ICurrentAPIs;
|
|
31
|
-
flattenedPlugins: Array<IPluginInfo & Partial<IFlattenedPlugin>>;
|
|
32
|
-
}): {
|
|
33
|
-
flattenedPlugins: Array<IFlattenedPlugin>;
|
|
34
|
-
badExports: IEntryMap;
|
|
35
|
-
};
|
|
36
|
-
export declare const handleMultipleReplaceRenderers: ({ flattenedPlugins, }: {
|
|
37
|
-
flattenedPlugins: Array<IFlattenedPlugin>;
|
|
38
|
-
}) => Array<IFlattenedPlugin>;
|
|
39
|
-
export declare function warnOnIncompatiblePeerDependency(name: string, packageJSON: PackageJson): void;
|
|
40
|
-
export {};
|
|
1
|
+
import { PackageJson } from "../../../";
|
|
2
|
+
import { IPluginInfo, IFlattenedPlugin, ISiteConfig } from "./types";
|
|
3
|
+
interface IApi {
|
|
4
|
+
version?: string;
|
|
5
|
+
}
|
|
6
|
+
export interface IEntry {
|
|
7
|
+
exportName: string;
|
|
8
|
+
pluginName: string;
|
|
9
|
+
pluginVersion: string;
|
|
10
|
+
api?: IApi;
|
|
11
|
+
}
|
|
12
|
+
export declare type ExportType = "node" | "browser" | "ssr";
|
|
13
|
+
declare type IEntryMap = {
|
|
14
|
+
[exportType in ExportType]: Array<IEntry>;
|
|
15
|
+
};
|
|
16
|
+
export declare type ICurrentAPIs = {
|
|
17
|
+
[exportType in ExportType]: Array<string>;
|
|
18
|
+
};
|
|
19
|
+
export declare function handleBadExports({ currentAPIs, badExports, }: {
|
|
20
|
+
currentAPIs: ICurrentAPIs;
|
|
21
|
+
badExports: {
|
|
22
|
+
[api in ExportType]: Array<IEntry>;
|
|
23
|
+
};
|
|
24
|
+
}): Promise<void>;
|
|
25
|
+
export declare function validateConfigPluginsOptions(config: ISiteConfig | undefined, rootDir: string): Promise<void>;
|
|
26
|
+
/**
|
|
27
|
+
* Identify which APIs each plugin exports
|
|
28
|
+
*/
|
|
29
|
+
export declare function collatePluginAPIs({ currentAPIs, flattenedPlugins, }: {
|
|
30
|
+
currentAPIs: ICurrentAPIs;
|
|
31
|
+
flattenedPlugins: Array<IPluginInfo & Partial<IFlattenedPlugin>>;
|
|
32
|
+
}): {
|
|
33
|
+
flattenedPlugins: Array<IFlattenedPlugin>;
|
|
34
|
+
badExports: IEntryMap;
|
|
35
|
+
};
|
|
36
|
+
export declare const handleMultipleReplaceRenderers: ({ flattenedPlugins, }: {
|
|
37
|
+
flattenedPlugins: Array<IFlattenedPlugin>;
|
|
38
|
+
}) => Array<IFlattenedPlugin>;
|
|
39
|
+
export declare function warnOnIncompatiblePeerDependency(name: string, packageJSON: PackageJson): void;
|
|
40
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const preferDefault: (m: any) => any;
|
|
1
|
+
export declare const preferDefault: (m: any) => any;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const writeRedirects: () => Promise<void>;
|
|
2
|
-
export declare const startRedirectListener: () => void;
|
|
1
|
+
export declare const writeRedirects: () => Promise<void>;
|
|
2
|
+
export declare const startRedirectListener: () => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { IGatsbyState, IRemoveStaleJobV2Action, ICreateJobV2FromInternalAction } from "../redux/types";
|
|
2
|
-
export declare const removeStaleJobs: (jobs: IGatsbyState["jobsV2"]) => Array<IRemoveStaleJobV2Action | ICreateJobV2FromInternalAction>;
|
|
1
|
+
import { IGatsbyState, IRemoveStaleJobV2Action, ICreateJobV2FromInternalAction } from "../redux/types";
|
|
2
|
+
export declare const removeStaleJobs: (jobs: IGatsbyState["jobsV2"]) => Array<IRemoveStaleJobV2Action | ICreateJobV2FromInternalAction>;
|