Properties
cm :CodeMirror
#
keymap :CodeMirrorKeymap
#
mwKeymapRegistry :Object.<Object.<CodeMirrorKeyBinding>>
#
Type:
preferences :CodeMirrorPreferences
#
textSelection :CodeMirrorTextSelection
#
view :EditorView
#
Methods
blockquote() → {boolean}
#
Format the selected text as a blockquote.
Returns:
- Type
- boolean
bold() → {boolean}
#
Bold the selected text.
Returns:
- Type
- boolean
comment() → {boolean}
#
Insert or toggle a comment around the selected text.
Returns:
- Type
- boolean
computerCode() → {boolean}
#
Format the selected text as computer code.
Returns:
- Type
- boolean
heading(level) → {boolean}
#
Change the current line to be a heading of the specified level.
Parameters:
| Name | Type | Description |
|---|---|---|
level |
number |
Returns:
- Type
- boolean
italic() → {boolean}
#
Italicize the selected text.
Returns:
- Type
- boolean
link() → {boolean}
#
Insert a link.
Returns:
- Type
- boolean
nowiki() → {boolean}
#
Treat the selected text as unformatted wikitext.
Returns:
- Type
- boolean
preformatted() → {boolean}
#
Format the selected text as preformatted.
Returns:
- Type
- boolean
reference() → {boolean}
#
Insert a reference.
Returns:
- Type
- boolean
registerKeyBindings()
#
Register each CodeMirrorKeyBinding with CodeMirrorKeymap,
and make the key bindings immediately available in the editor.
Register each CodeMirrorKeyBinding with CodeMirrorKeymap,
and make the key bindings immediately available in the editor.
strikethrough() → {boolean}
#
Format the selected text as strikethrough.
Returns:
- Type
- boolean
subscript() → {boolean}
#
Format the selected text as subscript.
Returns:
- Type
- boolean
superscript() → {boolean}
#
Format the selected text as superscript.
Returns:
- Type
- boolean
underline() → {boolean}
#
Format the selected text as underlined.
Returns:
- Type
- boolean