feat(editor): add lowlight code blocks - #3199
Merged
Merged
Conversation
AlexAndBear
force-pushed
the
feat/editor-codeblock-syntax-highlighting
branch
from
August 21, 2026 23:50
d9d0c36 to
79db1de
Compare
Member
Author
Build Size ComparisonI compared the build sizes between Editor Chunk Size
This PR (with lowlight):
Impact
The lowlight package (including the highlight.js themes) adds approximately 56 kB (gzipped) to the editor bundle. This is a noticeable but reasonable increase for syntax highlighting functionality. |
Member
|
I think it's fine for the scope of this PR, but we're already getting a warning about the biggest chunk, and now it's even more big. So we should make the editor components async and/or put them into dedicated chunks (kinda already a to-do in #3033). |
JammingBen
requested changes
Aug 24, 2026
JammingBen
left a comment
Member
There was a problem hiding this comment.
A few findings from my side:
- Inline blocks via single backticks
like thislost their styling. - The select is editable in read-only mode.
- The select overflows the code block initially, which looks a bit off. Maybe reduce its size? Or more general: do we really need this? 馃檲 I feel like this feature gets mostly used by technical users that now how to work with code blocks.
kulmann
reviewed
Aug 24, 2026
Member
Author
JammingBen
approved these changes
Aug 24, 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
This PR adds syntax-highlighted code blocks to the Tiptap editor using
@tiptap/extension-code-block-lowlightand a dedicated code block node view with language selection.It also switches Highlight.js themes based on the active app theme (
isDark):atom-one-lightatom-one-darkRelated Issue
How Has This Been Tested?
./node_modules/.bin/vue-tsc --declaration --noEmit --project packages/web-pkg/tsconfig.build.jsonTypes of changes