Store less unnecessary information in the linkable entities#1487
Draft
d-ronnqvist wants to merge 4 commits into
Draft
Store less unnecessary information in the linkable entities#1487d-ronnqvist wants to merge 4 commits into
d-ronnqvist wants to merge 4 commits into
Conversation
Only platform information is insufficient because symbols also check the presence of a DeprecationSummary when determining if they're deprecated. This information isn't reflected in external entities today, resulting in differences when such a page is referenced externally.
The navigator ultimately joins the navigator fragments into a plain string. By doing the same for external entities we avoid storing unnecessary data.
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.
Bug/issue #, if applicable:
Summary
This makes two changes to the linkable entities data:
c4c9fe2 stores to separate
isDeprecatedandisBetavalues instead of a list of platform information. Today, the platforms information is used to compute these two booleans when creating aTopicRenderReferencewhen a page is linked to externally.This change reduces the size of the linkable-entities.json file by between 10–30% depending on project.
4e582e9 stores the navigator title as a string instead of a list of declaration fragments. Today, the navigator fragments are joined into a string for the
NavigatorItemtitle.This change only reduces the size of the linkable-entities.json file by about 0.5–1.5% depending on project. The reason for this small change is that the vast majority of elements don't have a custom navigator title and those that do typically only have a single identifier fragment, meaning that the rare space savings is only:
Both changes are backwards compatible with older linkable-entities.json files.
Dependencies
None
Testing
TODO
Checklist
Make sure you check off the following items. If they cannot be completed, provide a reason.
./bin/testscript and it succeeded