8 lines
167 B
TypeScript
8 lines
167 B
TypeScript
|
import { EditorState } from "../deps.ts";
|
||
|
|
||
|
export function readonlyMode() {
|
||
|
return EditorState.changeFilter.of((tr): boolean => {
|
||
|
return !tr.docChanged;
|
||
|
});
|
||
|
}
|