Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(gatsby): PQR workers can access inference metadata (#31858)
* test(gatsby): check if worker can access node created in different process * make timeout longer for workerpool tests * test fixes from other pr * wip: saveStateForWorkers / loadStateInWorker * basic functionality + type fixes * wip (failing tests) * revert child * add redux state func * revert early return changes * initial * update tests and add env var * updates * send inference metadata * ignore all node_modules * rename GatsbyStateSlices type to GatsbyStateKeys to more accurately describe it * actually fix @babel/register * Restore pool.ts Co-authored-by: Michal Piechowiak <misiek.piechowiak@gmail.com> Co-authored-by: gatsbybot <mathews.kyle+gatsbybot@gmail.com>
- Loading branch information
1 parent
222a5ed
commit 315b694
Showing
5 changed files
with
56 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// Note: this doesn't check for conflicts between module exports | ||
export { renderHTMLProd, renderHTMLDev } from "./render-html" | ||
export { setQueries } from "./schema" | ||
export { setQueries, setInferenceMetadata } from "./schema" | ||
export { loadConfigAndPlugins } from "./load-config-and-plugins" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
import { setState } from "./state" | ||
|
||
export function setInferenceMetadata(): void { | ||
setState([`inferenceMetadata`]) | ||
} | ||
export function setQueries(): void { | ||
setState([`components`, `staticQueryComponents`]) | ||
} |