Onivim will automatically show code completion, when available. Code completion is only available in insert mode.
Completion items are fuzzy-matched, so typing
sdn will select
stdin in the example above.
- Control+n or Down - switch to next completion item.
- Control+p or Up - switch to previous completion item.
- Tab - complete the selected item.
Hover shows detailed information about a variable or identifier, as well as any diagnostic errors.
- gh normal mode - open hover
- Escape - close open hover
When available, signature help will be automatically opened when typing a trigger character (defined by the extension) - for example,
If a definition is available, the identifier will be underlined:
- gd will open the definition location.
= operator can be used to format, using the best available formatter.
- gg=G - format entire document
If no formatter is available, Onivim will fall-back to the language-defined indentation rules.
Onivim will automatically insert closing pairs, based on the language configuration settings.
For example, if the language defines
) as closing pairs, typing
( will insert
Typing the closing pair will result in the cursor 'passing through'. Pressing Backspace in a closing pair will remove both the opening and closing pair.
If the language extension supports it,
gO can be used to navigate to the symbol outline.