Yes! But I was thinking as an inline node, meaning instead of being a full width div, it just expands as the user types.
For instance, consider this paragraph with code as an inline codemirror in the middle of it. The part with code as an inline codemirror would be the codemirror instance.
Ah, no, CodeMirror assumes it is a block element, so for this you’d have to wrap it in some kind of inline-block container and add a kludge that constantly resizes it to match its content size. It won’t work as a regular content-fitting inline element.