Merged
Conversation
Signed-off-by: saurabhraghuvanshii <saurabhsraghuvanshi@gmail.com>
leecalcote
requested changes
Mar 25, 2026
| }); | ||
|
|
||
| // Normalize blog date to ISO string for stable sort order across build environments (fixes production blog order) | ||
| if (collection === "blog") { |
Member
There was a problem hiding this comment.
Why not just removing this condition? Why does the rest of the script need to change? You have not offered any description justifying the change.
Member
Author
There was a problem hiding this comment.
I didn’t change the script—only removed the condition. The rest are lint-related changes after removing that condition.
Member
There was a problem hiding this comment.
We keep running into this. Stop your linter from making all these changes.
Member
|
🚀 Preview for commit c2418af at: https://69c451c0e951a4b02b933838--layer5.netlify.app |
Member
|
🚀 Preview for commit b169207 at: https://69c45b01177babc5f652cb59--layer5.netlify.app |
leecalcote
approved these changes
Mar 26, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Gatsby builds GraphQL input types (like MdxFieldsSortInput) from fields it sees during schema inference.
In lightweight build profile, blog nodes are excluded.
If dateForSort is only created for blog nodes, Gatsby never sees that field in this build.
Then any query that says sort: { fields: { dateForSort: DESC } } fails at compile time with: Field "dateForSort" is not defined by type "MdxFieldsSortInput".
This PR fixes #7556
Notes for Reviewers
Signed commits