Is there an existing issue for this?
Describe the bug
@lexical/code-shiki takes almost half of the main _app bundle due to how code-shiki is built and published. Single-file output takes all the imports and bundles them in the output, thus all of the Shiki internal imports are included, causing an output of ~9MB.
Screenshots
_app bundle containing code-shiki
Steps To Reproduce
- Load SN
- Shiki is fully loaded
Expected behavior
Every code block (CodeNode) should fetch the code language and theme on-demand, just like Shiki behaves by default.
Logs
No response
Device information
No response
Additional context
This is a bug in Lexical's build configuration, we either need to wait for them to fix this or we can copy their code-shiki package and do it ourselves.
Lexical bug: facebook/lexical#8515
Is there an existing issue for this?
Describe the bug
@lexical/code-shikitakes almost half of the main_appbundle due to howcode-shikiis built and published. Single-file output takes all the imports and bundles them in the output, thus all of the Shiki internal imports are included, causing an output of ~9MB.Screenshots
_appbundle containingcode-shikiSteps To Reproduce
Expected behavior
Every code block (
CodeNode) should fetch the code language and theme on-demand, just like Shiki behaves by default.Logs
No response
Device information
No response
Additional context
This is a bug in Lexical's build configuration, we either need to wait for them to fix this or we can copy their
code-shikipackage and do it ourselves.Lexical bug: facebook/lexical#8515