0

I'm using prism.js to highlight some css in a <pre contenteditable="true"> tag in a settup very similar to this one.

On keyup I copy the code to a hidden <textarea> but the output is the highlighted text such as:

<span class="token selector">#description </span><span class="token punctuation">{</span><br>
<span class="token property">cursor</span><span class="token punctuation">:</span>
... etc.

Is there a way to get the un-highlighted text to be able to save it in its clean original format?

pachanka
  • 391
  • 4
  • 16

0 Answers0