Email or username:

Password:

Forgot your password?
Top-level
Ьλ∂λ

@cheeaun @bramus I was thinking of hacking something for textarea based on github.com/kueblc/LDT

(which overlays a transparent <textarea> on top of a styled <pre>)

Not sure the highlight API has been thought out for dynamic content... I don't know if you can change the bounds of a range after it's been registered and have the output updated... We'll see 🙂

3 comments
Ьλ∂λ

@bramus @cheeaun

That makes LDT redundant...

Prism is ~10Kb larger, but its parsing abilities is heaps and bounds better than what LDT offers with just regexps.

Prism also supports styling the content of script and style tags in HTML, out of the box...

Ьλ∂λ

@bramus @cheeaun FWIW, you may want to add

spellcheck="false"

On the contenteditable elements, otherwise "Bramus" is styled as a spelling mistake on click.

Somehow "const" and "EOF" are deemed acceptable.

Go Up