hoist-react
hoist-react copied to clipboard
Update `codemirror -> 6.x`
Thought this might be a drop-in upgrade as changes in https://github.com/codemirror/basic-setup/blob/main/CHANGELOG.md looked minimal, but I believe something might have changed with their default exports. Needs a bit of a closer look.
Changes from version 5 to 6 are major.
Version 6 exposes only modules, and the entire library has been split into separate packages, requiring more manual configuration. Other changes that I am aware of: events are handled differently, functionality and decoration is passed to the editor through extensions (I believe similar to editorSpec in the v5 hoist version but implemented differently), and the fromTextArea
method is no longer supported (although the docs do provide a function with similar behavior).
Some documentation specifically about version 5 to 6 migration is available here in addition to the normal docs, which are quite thorough.