This is my attempt to learn how to use CodeMirror with this extension: https://github.com/replit/codemirror-interact[1] , which lets you alt-drag numbers to change them (scrubbing interface):
1 Setup#
I started by setting up CodeMirror using https://codemirror.net/examples/basic/[2] and https://codemirror.net/docs/guide/[3]. It took some time to figure out how to connect the parts to make a minimal working example where I could read the text out, not just initialize it.
pnpm install @codemirror/state @codemirror/view @codemirror/commands @codemirror/language @codemirror/lang-xml @replit/codemirror-interact
Source: scrubbable-codemirror.js