Interface IEditorLanguage

The interface of a codemirror language specification.

interface IEditorLanguage {
    alias?: readonly string[];
    displayName?: string;
    extensions?: readonly string[];
    filename?: RegExp;
    load?: (() => Promise<LanguageSupport>);
    mime: string | readonly string[];
    name: string;
    support?: LanguageSupport;


alias?: readonly string[]

Language name alias.

displayName?: string

Language displayed name.

extensions?: readonly string[]

Supported file extensions.

filename?: RegExp

Filename expression supported by the language.

load?: (() => Promise<LanguageSupport>)

Language support loader.

Type declaration

mime: string | readonly string[]

Language mime types.

name: string

Language name.

support?: LanguageSupport

CodeMirror language support.


It can provided directly or it will be obtained using load.