Self-host Prism and fix the code-block flash - #58
Merged
Conversation
Write the language class into the 296 code blocks that previously received it from JavaScript at runtime, removing a 150 to 450 ms window in which code rendered in Consolas at 16 px with no box before snapping into place. Replace the four cross-origin Prism requests with one self-hosted bundle carrying only the grammars the site uses, fold the needed theme rules into the stylesheet, add the missing TypeScript grammar, and align the light-mode token colours on the two root pages with the docs palette.
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Write the language class into the 296 code blocks that previously received it from JavaScript at runtime, removing a 150 to 450 ms window in which code rendered in Consolas at 16 px with no box before snapping into place. Replace the four cross-origin Prism requests with one self-hosted bundle carrying only the grammars the site uses, fold the needed theme rules into the stylesheet, add the missing TypeScript grammar, and align the light-mode token colours on the two root pages with the docs palette.