Original link: https://spacevim.org/cn/layers/lang/elixir/
- Module Introduction
- Functional characteristics
- Enable module
- Shortcut keys
- Language-specific shortcut keys
- Interactive programming
- Run the current script
Module Introduction
This module provides elixir development support for Spacevim, including code completion, syntax checking, and formatting of code.
Functional characteristics
This module mainly includes plug-in Slashmili/alchemist.vim, which provides:
- Code completion
- Document Query
- Jump definition at
At the same time, Spacevim also provides interactive programming, one-click operation and Language server for Elixir development. To enable a language server, you need to load the lsp
module.
Enable module
You can enable the module by adding the following configuration to the configuration file:
[[layers]] name = "lang#elixir"
Shortcut key language Exclusive shortcuts
Key |
function Description |
SPC l d /K |
Show cursor functions or variables related documents |
SPC l t |
Skip to Tag Stack |
SPC l e |
Rename cursor function or variable (requires lsp module) |
g d |
Jump to function or variable definition |
Interactive programming
Start iex
The interactive process, the shortcut key is: SPC l s i
.
Transfer code to the REPL process execution:
shortcut Keys |
Description |
SPC l s b |
Send entire file contents to REPL |
SPC l s l |
Send current line contents to REPL |
SPC l s s |
Send the selected content to REPL |
Run the current script
When editing the elixir file, you can SPC l r
quickly and asynchronously run the current file by using the shortcut key, and the result of the run is displayed in a separate execution window.
Spacevim Language Module Elixir