react-codemirror
react-codemirror copied to clipboard
Disable drag and drop fonctionnality
Is there a way to disable drag and drop? I saw that there is a dragDrop property but don't know where to put it. Also tried to add event extensions and return false on drop but nothing seems to work
https://github.com/uiwjs/react-codemirror/blob/73b518e0601409e0f113a62cad89355a5115396c/extensions/events/README.md?plain=1#L92-L131
npm install @uiw/codemirror-extensions-events --save
import * as events from '@uiw/codemirror-extensions-events';
const extension1 = events.scroll({
scroll: (evn) => {
console.log(evn.target.scrollTop);
},
});
const extension2 = events.content({
focus: (evn) => {
console.log('focus');
},
blur: (evn) => {
console.log('blur');
},
});
@mickeld23 https://uiwjs.github.io/react-codemirror/#/extensions/events