Liking cljdoc? Tell your friends :D

dots.vscode.completion-item

A completion item represents a text snippet that is proposed to complete text that is being typed.

It is sufficient to create a completion item from just a {@link CompletionItem.label label}. In that case the completion item will replace the {@link TextDocument.getWordRangeAtPosition word} until the cursor with the given label or {@link CompletionItem.insertText insertText}. Otherwise the given {@link CompletionItem.textEdit edit} is used.

When selecting a completion item in the editor its defined or synthesized text edit will be applied to all cursors/selections whereas {@link CompletionItem.additionalTextEdits additionalTextEdits} will be applied as provided.

A completion item represents a text snippet that is proposed to complete text that is being typed.

It is sufficient to create a completion item from just a {@link CompletionItem.label label}. In that
case the completion item will replace the {@link TextDocument.getWordRangeAtPosition word}
until the cursor with the given label or {@link CompletionItem.insertText insertText}. Otherwise the
given {@link CompletionItem.textEdit edit} is used.

When selecting a completion item in the editor its defined or synthesized text edit will be applied
to *all* cursors/selections whereas {@link CompletionItem.additionalTextEdits additionalTextEdits} will be
applied as provided.
raw docstring

additional-text-editscljs

(additional-text-edits completion-item)

An optional array of additional {@link TextEdit text edits} that are applied when selecting this completion. Edits must not overlap with the main {@link CompletionItem.textEdit edit} nor with themselves.

Returns: TextEdit[] | undefined

An optional array of additional {@link TextEdit text edits} that are applied when
selecting this completion. Edits must not overlap with the main {@link CompletionItem.textEdit edit}
nor with themselves.

**Returns:** `TextEdit[] | undefined`
sourceraw docstring

commandcljs

(command completion-item)

An optional {@link Command } that is executed after inserting this completion. Note that additional modifications to the current document should be described with the {@link CompletionItem.additionalTextEdits additionalTextEdits}-property.

Returns: Command | undefined

An optional {@link Command } that is executed *after* inserting this completion. *Note* that
additional modifications to the current document should be described with the
{@link CompletionItem.additionalTextEdits additionalTextEdits}-property.

**Returns:** `Command | undefined`
sourceraw docstring

commit-characterscljs

(commit-characters completion-item)

An optional set of characters that when pressed while this completion is active will accept it first and then type that character. Note that all commit characters should have length=1 and that superfluous characters will be ignored.

Returns: string[] | undefined

An optional set of characters that when pressed while this completion is active will accept it first and
then type that character. *Note* that all commit characters should have `length=1` and that superfluous
characters will be ignored.

**Returns:** `string[] | undefined`
sourceraw docstring

detailcljs

(detail completion-item)

A human-readable string with additional information about this item, like type or symbol information.

Returns: string | undefined

A human-readable string with additional information
about this item, like type or symbol information.

**Returns:** `string | undefined`
sourceraw docstring

documentationcljs

(documentation completion-item)

A human-readable string that represents a doc-comment.

Returns: string | MarkdownString | undefined

A human-readable string that represents a doc-comment.

**Returns:** `string | MarkdownString | undefined`
sourceraw docstring

filter-textcljs

(filter-text completion-item)

A string that should be used when filtering a set of completion items. When falsy the {@link CompletionItem.label label} is used.

Note that the filter text is matched against the leading word (prefix) which is defined by the {@linkcode CompletionItem.range range}-property.

Returns: string | undefined

A string that should be used when filtering a set of
completion items. When `falsy` the {@link CompletionItem.label label}
is used.

Note that the filter text is matched against the leading word (prefix) which is defined
by the {@linkcode CompletionItem.range range}-property.

**Returns:** `string | undefined`
sourceraw docstring

insert-textcljs

(insert-text completion-item)

A string or snippet that should be inserted in a document when selecting this completion. When falsy the {@link CompletionItem.label label} is used.

Returns: string | SnippetString | undefined

A string or snippet that should be inserted in a document when selecting
this completion. When `falsy` the {@link CompletionItem.label label}
is used.

**Returns:** `string | SnippetString | undefined`
sourceraw docstring

keep-whitespace?cljs

(keep-whitespace? completion-item)

Keep whitespace of the {@link CompletionItem.insertText insertText} as is. By default, the editor adjusts leading whitespace of new lines so that they match the indentation of the line for which the item is accepted - setting this to true will prevent that.

Returns: boolean | undefined

Keep whitespace of the {@link CompletionItem.insertText insertText} as is. By default, the editor adjusts leading
whitespace of new lines so that they match the indentation of the line for which the item is accepted - setting
this to `true` will prevent that.

**Returns:** `boolean | undefined`
sourceraw docstring

kindcljs

(kind completion-item)

The kind of this completion item. Based on the kind an icon is chosen by the editor.

Returns: CompletionItemKind | undefined

The kind of this completion item. Based on the kind
an icon is chosen by the editor.

**Returns:** `CompletionItemKind | undefined`
sourceraw docstring

labelcljs

(label completion-item)

The label of this completion item. By default this is also the text that is inserted when selecting this completion.

Returns: string | CompletionItemLabel

The label of this completion item. By default
this is also the text that is inserted when selecting
this completion.

**Returns:** `string | CompletionItemLabel`
sourceraw docstring

preselect?cljs

(preselect? completion-item)

Select this item when showing. Note that only one completion item can be selected and that the editor decides which item that is. The rule is that the first item of those that match best is selected.

Returns: boolean | undefined

Select this item when showing. *Note* that only one completion item can be selected and
that the editor decides which item that is. The rule is that the *first* item of those
that match best is selected.

**Returns:** `boolean | undefined`
sourceraw docstring

rangecljs

(range completion-item)

A range or a insert and replace range selecting the text that should be replaced by this completion item.

When omitted, the range of the {@link TextDocument.getWordRangeAtPosition current word} is used as replace-range and as insert-range the start of the {@link TextDocument.getWordRangeAtPosition current word} to the current position is used.

Note 1: A range must be a {@link Range.isSingleLine single line} and it must {@link Range.contains contain} the position at which completion has been {@link CompletionItemProvider.provideCompletionItems requested}. Note 2: A insert range must be a prefix of a replace range, that means it must be contained and starting at the same position.

Returns: Range | { inserting: Range; replacing: Range; } | undefined

A range or a insert and replace range selecting the text that should be replaced by this completion item.

When omitted, the range of the {@link TextDocument.getWordRangeAtPosition current word} is used as replace-range
and as insert-range the start of the {@link TextDocument.getWordRangeAtPosition current word} to the
current position is used.

*Note 1:* A range must be a {@link Range.isSingleLine single line} and it must
{@link Range.contains contain} the position at which completion has been {@link CompletionItemProvider.provideCompletionItems requested}.
*Note 2:* A insert range must be a prefix of a replace range, that means it must be contained and starting at the same position.

**Returns:** `Range | { inserting: Range; replacing: Range; } | undefined`
sourceraw docstring

set-additional-text-edits!cljs

(set-additional-text-edits! completion-item value)

An optional array of additional {@link TextEdit text edits} that are applied when selecting this completion. Edits must not overlap with the main {@link CompletionItem.textEdit edit} nor with themselves.

An optional array of additional {@link TextEdit text edits} that are applied when
selecting this completion. Edits must not overlap with the main {@link CompletionItem.textEdit edit}
nor with themselves.
sourceraw docstring

set-command!cljs

(set-command! completion-item value)

An optional {@link Command } that is executed after inserting this completion. Note that additional modifications to the current document should be described with the {@link CompletionItem.additionalTextEdits additionalTextEdits}-property.

An optional {@link Command } that is executed *after* inserting this completion. *Note* that
additional modifications to the current document should be described with the
{@link CompletionItem.additionalTextEdits additionalTextEdits}-property.
sourceraw docstring

set-commit-characters!cljs

(set-commit-characters! completion-item value)

An optional set of characters that when pressed while this completion is active will accept it first and then type that character. Note that all commit characters should have length=1 and that superfluous characters will be ignored.

An optional set of characters that when pressed while this completion is active will accept it first and
then type that character. *Note* that all commit characters should have `length=1` and that superfluous
characters will be ignored.
sourceraw docstring

set-detail!cljs

(set-detail! completion-item value)

A human-readable string with additional information about this item, like type or symbol information.

A human-readable string with additional information
about this item, like type or symbol information.
sourceraw docstring

set-documentation!cljs

(set-documentation! completion-item value)

A human-readable string that represents a doc-comment.

A human-readable string that represents a doc-comment.
sourceraw docstring

set-filter-text!cljs

(set-filter-text! completion-item value)

A string that should be used when filtering a set of completion items. When falsy the {@link CompletionItem.label label} is used.

Note that the filter text is matched against the leading word (prefix) which is defined by the {@linkcode CompletionItem.range range}-property.

A string that should be used when filtering a set of
completion items. When `falsy` the {@link CompletionItem.label label}
is used.

Note that the filter text is matched against the leading word (prefix) which is defined
by the {@linkcode CompletionItem.range range}-property.
sourceraw docstring

set-insert-text!cljs

(set-insert-text! completion-item value)

A string or snippet that should be inserted in a document when selecting this completion. When falsy the {@link CompletionItem.label label} is used.

A string or snippet that should be inserted in a document when selecting
this completion. When `falsy` the {@link CompletionItem.label label}
is used.
sourceraw docstring

set-keep-whitespace!cljs

(set-keep-whitespace! completion-item value)

Keep whitespace of the {@link CompletionItem.insertText insertText} as is. By default, the editor adjusts leading whitespace of new lines so that they match the indentation of the line for which the item is accepted - setting this to true will prevent that.

Keep whitespace of the {@link CompletionItem.insertText insertText} as is. By default, the editor adjusts leading
whitespace of new lines so that they match the indentation of the line for which the item is accepted - setting
this to `true` will prevent that.
sourceraw docstring

set-kind!cljs

(set-kind! completion-item value)

The kind of this completion item. Based on the kind an icon is chosen by the editor.

The kind of this completion item. Based on the kind
an icon is chosen by the editor.
sourceraw docstring

set-label!cljs

(set-label! completion-item value)

The label of this completion item. By default this is also the text that is inserted when selecting this completion.

The label of this completion item. By default
this is also the text that is inserted when selecting
this completion.
sourceraw docstring

set-preselect!cljs

(set-preselect! completion-item value)

Select this item when showing. Note that only one completion item can be selected and that the editor decides which item that is. The rule is that the first item of those that match best is selected.

Select this item when showing. *Note* that only one completion item can be selected and
that the editor decides which item that is. The rule is that the *first* item of those
that match best is selected.
sourceraw docstring

set-range!cljs

(set-range! completion-item value)

A range or a insert and replace range selecting the text that should be replaced by this completion item.

When omitted, the range of the {@link TextDocument.getWordRangeAtPosition current word} is used as replace-range and as insert-range the start of the {@link TextDocument.getWordRangeAtPosition current word} to the current position is used.

Note 1: A range must be a {@link Range.isSingleLine single line} and it must {@link Range.contains contain} the position at which completion has been {@link CompletionItemProvider.provideCompletionItems requested}. Note 2: A insert range must be a prefix of a replace range, that means it must be contained and starting at the same position.

A range or a insert and replace range selecting the text that should be replaced by this completion item.

When omitted, the range of the {@link TextDocument.getWordRangeAtPosition current word} is used as replace-range
and as insert-range the start of the {@link TextDocument.getWordRangeAtPosition current word} to the
current position is used.

*Note 1:* A range must be a {@link Range.isSingleLine single line} and it must
{@link Range.contains contain} the position at which completion has been {@link CompletionItemProvider.provideCompletionItems requested}.
*Note 2:* A insert range must be a prefix of a replace range, that means it must be contained and starting at the same position.
sourceraw docstring

set-sort-text!cljs

(set-sort-text! completion-item value)

A string that should be used when comparing this item with other items. When falsy the {@link CompletionItem.label label} is used.

Note that sortText is only used for the initial ordering of completion items. When having a leading word (prefix) ordering is based on how well completions match that prefix and the initial ordering is only used when completions match equally well. The prefix is defined by the {@linkcode CompletionItem.range range}-property and can therefore be different for each completion.

A string that should be used when comparing this item
with other items. When `falsy` the {@link CompletionItem.label label}
is used.

Note that `sortText` is only used for the initial ordering of completion
items. When having a leading word (prefix) ordering is based on how
well completions match that prefix and the initial ordering is only used
when completions match equally well. The prefix is defined by the
{@linkcode CompletionItem.range range}-property and can therefore be different
for each completion.
sourceraw docstring

set-tags!cljs

(set-tags! completion-item value)

Tags for this completion item.

Tags for this completion item.
sourceraw docstring

set-text-edit!cljs

(set-text-edit! completion-item value)
source

sort-textcljs

(sort-text completion-item)

A string that should be used when comparing this item with other items. When falsy the {@link CompletionItem.label label} is used.

Note that sortText is only used for the initial ordering of completion items. When having a leading word (prefix) ordering is based on how well completions match that prefix and the initial ordering is only used when completions match equally well. The prefix is defined by the {@linkcode CompletionItem.range range}-property and can therefore be different for each completion.

Returns: string | undefined

A string that should be used when comparing this item
with other items. When `falsy` the {@link CompletionItem.label label}
is used.

Note that `sortText` is only used for the initial ordering of completion
items. When having a leading word (prefix) ordering is based on how
well completions match that prefix and the initial ordering is only used
when completions match equally well. The prefix is defined by the
{@linkcode CompletionItem.range range}-property and can therefore be different
for each completion.

**Returns:** `string | undefined`
sourceraw docstring

tagscljs

(tags completion-item)

Tags for this completion item.

Returns: readonly CompletionItemTag[] | undefined

Tags for this completion item.

**Returns:** `readonly CompletionItemTag[] | undefined`
sourceraw docstring

text-editcljs

(text-edit completion-item)

Returns: TextEdit | undefined

**Returns:** `TextEdit | undefined`
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close