3 ms·
I've never used CodeMirror, but I'm using ProseMirror by the same author and it relies a lot on having control of the DOM. I'm guessing the integration will be
by pier25 6y ago
I've never used CodeMirror, but I'm using ProseMirror by the same author and it relies a lot on having control of the DOM.
I'm guessing the integration will be basically a wrapper component with a ref of a DOM node where CodeMirror will do its thing.
- dmitryminkovsky 6y ago> I'm guessing the integration will be basically a wrapper component with a ref of a DOM node where CodeMirror will do its thing. Pretty much. This is how my React ProseMirror integration works: https://github.com/dminkovsky/use-prosemirror/blob/main/src/ProseMirror.tsx https://github.com/dminkovsky/use-prosemirror/blob/main/src/.... Though there are some complexities. I believe CodeMirror would be the same.