UNPKG

@remirror/extension-codemirror5

Version:
23 lines (22 loc) 779 B
import type CodeMirrorNamespace from 'codemirror'; type CodeMirrorType = typeof CodeMirrorNamespace; /** * When codemirror is loaded immediately in non-browser environments it throws * an error. * * Non async dynamic imports are impossible without better build tooling. For * now, it the best compromise is to export a mutable object which dynamically * inject the CodeMirror instance when required. */ declare const ref: { CodeMirror: CodeMirrorType; }; export default ref; /** * Load codemirror asynchronously for SSR support. * * @deprecated Please pass the CodeMirror instance to the CodeMirrorExtension * manually. Runtime dynamic imports can be different based on your * environment and bundler. */ export declare function loadCodeMirror(): Promise<void>;