Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(gatsby): stitch slices if just page html was regenerating without any of used slices regenerating #36950

Merged
merged 1 commit into from
Nov 3, 2022

Conversation

pieh
Copy link
Contributor

@pieh pieh commented Nov 3, 2022

Description

We currently mark html for (re)stitching when:

  • slices used by a page changed (special case is first time slice is produced - it is like it changed from nothing to something)
  • when special scripts slice is regenerated (basically when browser bundle changes)

But we were not (re)stitching when just base page was regenerated and none of the slices used by a page did (there might be 0 user slices, there is always at least 1 special gatsby scripts slice).

This result in following empty slice placeholder on outputted html:
image

This PR just makes sure we mark page for (re)stitching if it was regenerated

@gatsbot gatsbot bot added the status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer label Nov 3, 2022
@pieh pieh added topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) and removed status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer labels Nov 3, 2022
@pieh pieh merged commit 3044280 into master Nov 3, 2022
@pieh pieh deleted the fix/stitch-slices-in-if-just-html-page-regenerated branch November 3, 2022 11:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants