3 ms·
Marijn Haverbeke (CodeMirror/ProseMirror) wrote about the pitfalls of contenteditable: - https://marijnhaverbeke.nl/blog/prosemirror.html https://marijnhaverbe
by Leftium 3y ago
Marijn Haverbeke (CodeMirror/ProseMirror) wrote about the pitfalls of contenteditable:
- https://marijnhaverbeke.nl/blog/prosemirror.html https://marijnhaverbeke.nl/blog/prosemirror.html
- https://codemirror.net/5/doc/internals.html https://codemirror.net/5/doc/internals.html
Things may be different in 2023. In fact, CodeMirror 6 was designed on top of contenteditable:
> It's underspecified and very hard to implement (and hence, not implemented all that well), but if you know the pitfalls (only some DOM/style structures are well supported, cursors vanish in some circumstances, etc) and avoid them, and implement non-trivial editing commands yourself (because you can't really rely on the browser to get them right), contentEditable is a functional way to represent editable content in the browser.
- https://hw.leftium.com/#/item/17858947 https://hw.leftium.com/#/item/17858947
- https://web.archive.org/web/20181109055050/https://codemirror.net/6/design.html https://web.archive.org/web/20181109055050/https://codemirro...
- https://web.archive.org/web/20180828134646/https://codemirror.net/6/ https://web.archive.org/web/20180828134646/https://codemirro...