1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-03-24 10:47:07 +08:00
SpaceVim/docs/layers/lang/javascript.md
2018-06-23 14:37:41 +08:00

2.1 KiB

title description
SpaceVim lang#javascript layer This layer is for JaveScript development

Available Layers >> lang#javascript

Description

This layer is for JavaScript development.

Install

To use this configuration layer, update custom configuration file with:

[[layers]]
  name = "lang#javascript"

Features

  • auto-completion
  • syntax checking
  • goto definition
  • refernce finder

Layer configuration

auto_fix: auto fix problems when save files, disabled by default. If you need this feature, you can load this layer via:

call SpaceVim#layers#load('lang#javascript',
            \ {
            \ 'auto_fix' : 1,
            \ }
            \ )

enable_flow_syntax: Enable configuration for flow, disabled by default. If you need this feature, you can load this layer via:

call SpaceVim#layers#load('lang#javascript',
            \ {
            \ 'enable_flow_syntax' : 1,
            \ }
            \ )

Key bindings

Import key bindings

Key Binding Description
F4 (Insert/Normal) Import symbol under cursor
SPC j i Import symbol under cursor
SPC j f Import missing symbols
SPC j g Jump to module under cursor
<C-j>i (Insert) Import symbol under cursor
<C-j>f (Insert) Import missing symbols
<C-j>g (Insert) Jump to module under cursor

Generate key bindings

Mode Key Binding Description
normal SPC l g d Generate JSDoc