Optional
$blockOptional
$codeOptional
$multiselectOptional
$optionsOptional
$updateOptional
$updateAdds the selection and cursor.
Aligns the cursors or selected text.
Optional
cmdOptional
codeOptional
completer}
Optional
elasticOptional
envRemoves all the selections except the last added one.
Finds and selects all the occurrences of needle
.
Optional
needle: stringThe text to find
Optional
options: Partial<SearchOptions>The search options
Optional
additive: booleankeeps
The cumulative count of all found matches
Executes a command for each selection range.
The command to execute
Optional
args: stringAny arguments for the command
Optional
options: ObjectOptional
inOptional
isOptional
multiRemoves the selection marker.
Optional
searchOptional
selectedFinds the next occurrence of text in an active selection and adds it to the selections.
The direction of lines to select: -1 for up, 1 for down
Optional
skip: booleanIf true
, removes the active selection range
Optional
stopAtFirst: booleanAdds a cursor above or below the active cursor.
The direction of lines to select: -1 for up, 1 for down
Optional
skip: booleanIf true
, removes the active selection range
Optional
setOptional
showOptional
showTransposes the selected ranges.
The direction to rotate selections
Updates the cursor and marker layers.
Optional
widgetOptional
capturing: booleanOptional
capturing: booleanAttempts to find needle
within the document. For more information on options
, see [[Search Search
]].
The text to search for (optional)
Optional
options: Partial<SearchOptions>An object defining various search properties
Optional
animate: booleanIf true
animate scrolling
Performs another search for needle
in the document. For more information on options
, see [[Search Search
]].
Optional
options: Partial<SearchOptions>search options
Optional
animate: booleanIf true
animate scrolling
Performs a search for needle
backwards. For more information on options
, see [[Search Search
]].
Optional
options: Partial<SearchOptions>search options
Optional
animate: booleanIf true
animate scrolling
{:Search.getOptions} For more information on options
, see [[Search Search
]].
Optional
optionNames: Partial<EditorOptions> | (keyof EditorOptions)[]Returns the current session being used.
Moves the cursor to the specified line number, and also into the indicated column.
The line number to go to
Optional
column: numberA column number to go to
Optional
animate: booleanIf true
animates scolling
Optional
capturing: booleanOptional
capturing: booleanReplaces the first occurrence of options.needle
with the value in replacement
.
Optional
replacement: stringThe text to replace with
Optional
options: Partial<SearchOptions>The [[Search Search
]] options to use
Replaces all occurrences of options.needle
with the value in replacement
.
Optional
replacement: stringThe text to replace with
Optional
options: Partial<SearchOptions>The [[Search Search
]] options to use
Scrolls to a line. If center
is true
, it puts the line in middle of screen (or attempts to).
The line to scroll to
If true
If true
animates scrolling
Optional
callback: () => voidFunction to be called when the animation has finished
Set the "ghost" text in provided position. "Ghost" text is a kind of preview text inside the editor which can be used to preview some code inline in the editor such as, for example, code completions.
Text to be inserted as "ghost" text
Optional
position: PointPosition to insert text to
Sets a new key handler, such as "vim" or "windows".
The new key handler
Optional
cb: () => voidPass in true
to enable overwrites in your session, or false
to disable. If overwrites is enabled, any text you enter will type over any text after it. If the value of overwrite
changes, this function also emits the changeOverwrite
event.
Defines whether or not to set overwrites
Sets a new editsession to use. This method also emits the 'changeSession'
event.
Optional
session: EditSessionThe new session to use
Sets the current document to val
.
The new value to set for the document
Optional
cursorPos: numberWhere to set the new value. undefined
or 0 is selectAll, -1 is at the document start, and 1 is at the end
The current document value
This object is used in some places where needed to show popups - like prompt; autocomplete etc.