chore: collapse generated docs files in PR diffs (linguist-generated)#4046
Merged
Conversation
|
Preview removedAll preview folders cleaned from gh-pages branch. |
ArakTaiRoth
approved these changes
Jun 19, 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.
What this does
Marks the committed generated docs files as
linguist-generatedso GitHub collapses them by default in the Files Changed tab. They stay fully diffable, searchable, and in history. They're just hidden behind a one-click expand so real changes are easier to spot in review.Two entries in a new
.gitattributes:docs/generated/** linguist-generated=true: covers the committed component API JSON today, plus any future generator that commits output underdocs/generated/.docs/public/search-index.json linguist-generated=true: the search index, which lives outsidedocs/generated/.Scope
Display metadata only. No merge-driver or text/eol attributes. The merge driver stays parked until parallel PRs actually start conflicting on these files.
When you'll see it
GitHub applies
linguist-generatedfrom the repo's default branch (dev), so it takes effect once this merges. You won't see any collapse on this PR; it shows up on later PRs whose diffs include a generated file. This PR just adds the rule.