Closed ysk3a closed 3 months ago
The readOnlyCodeFolding
extension requires styles from prism-code-editor/code-folding.css
. I'll usually document it if an extension requires extra styling, but I forgot to do so here. I will fix that.
I see.
It appears adding import 'prism-code-editor/code-folding.css';
in addition to 'readOnlyCodeFolding` seems to have fixed the new line behavior as you have mentioned.
Thanks for the quick response! 👍
I'm not sure if this is just in the demo but i've also noticed an odd behavior in the examples under the example section.
The provided examples were mostly non readonly examples, that is, the examples did not use readonlyeditor() or use the readOnlyCodeFolding option. So I tried to add them to see how it would look like and for some odd reason adding readOnlyCodeFolding add extra new lines at various locations.
forking one of the stackblitz examples, i've added the folding option and theres new lines added? https://stackblitz.com/edit/vitejs-vite-ympxkc?file=src%2Fmain.ts
original:
after adding readOnlyCodeFolding: