You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So far, I've used it to highlight the code snippets, and it works great!
Now, I would like to extend it and make highlighted code snippets editable (web-based code editor like Prism live).
On the Prism live site, I haven't found any example with the resizable editor (no scrollbars).
Adjusting CSS to make the editor resizable (mostly adding white-space: pre-wrap; and overflow: hidden), I've encountered the issue attached below. It seems that the solution with layered textarea and pre elements has some drawbacks (probably something with differently breaking text in textarea and highlighted content under pre element).
To get back to the problem 😄, is there any recommended way that Prism live plans to adopt to support resizable code editors in browsers?
TIA
The text was updated successfully, but these errors were encountered:
I've checked the proposed solution, but it does not solve my problem :/.
Also, I've created an additional question on the StackOverflow.
I hope someone managed to solve this problem as I wouldn't want to add an extra library just for that...
I've checked the proposed solution, but it does not solve my problem :/.
Also, I've created an additional question on the StackOverflow.
I hope someone managed to solve this problem as I wouldn't want to add an extra library just for that...
Many thanks for the PrismJS!
So far, I've used it to highlight the code snippets, and it works great!
Now, I would like to extend it and make highlighted code snippets editable (web-based code editor like Prism live).
On the Prism live site, I haven't found any example with the resizable editor (no scrollbars).
Adjusting CSS to make the editor resizable (mostly adding
white-space: pre-wrap;
andoverflow: hidden
), I've encountered the issue attached below. It seems that the solution with layeredtextarea
andpre
elements has some drawbacks (probably something with differently breaking text intextarea
and highlighted content underpre
element).To get back to the problem 😄, is there any recommended way that Prism live plans to adopt to support resizable code editors in browsers?
TIA
The text was updated successfully, but these errors were encountered: