* chore: add precommit hook for eslint fixes, fix linting issues * chore: add eslint import sort plugin
19 lines
369 B
TypeScript
19 lines
369 B
TypeScript
import { Plugin, PluginKey } from 'prosemirror-state'
|
|
|
|
import { Extension } from '../Extension'
|
|
|
|
export const Editable = Extension.create({
|
|
name: 'editable',
|
|
|
|
addProseMirrorPlugins() {
|
|
return [
|
|
new Plugin({
|
|
key: new PluginKey('editable'),
|
|
props: {
|
|
editable: () => this.editor.options.editable,
|
|
},
|
|
}),
|
|
]
|
|
},
|
|
})
|