diff options
Diffstat (limited to 'after/indent')
-rw-r--r-- | after/indent/javascript.vim | 2 | ||||
-rw-r--r-- | after/indent/javascriptreact.vim | 5 | ||||
-rw-r--r-- | after/indent/typescript.vim | 2 | ||||
-rw-r--r-- | after/indent/typescriptreact.vim | 5 |
4 files changed, 12 insertions, 2 deletions
diff --git a/after/indent/javascript.vim b/after/indent/javascript.vim index f183061c..24b7f937 100644 --- a/after/indent/javascript.vim +++ b/after/indent/javascript.vim @@ -21,7 +21,7 @@ if exists('s:did_indent') endif setlocal indentexpr=GetJsxIndent() -setlocal indentkeys=0{,0},0),0],0?,0\*,0\,,!^F,:,<:>,o,O,e,<>>,=*/ +setlocal indentkeys=0.,0{,0},0),0],0?,0\*,0\,,!^F,:,<:>,o,O,e,<>>,=*/ function! GetJsxIndent() return jsx_pretty#indent#get(function('GetJavascriptIndent')) diff --git a/after/indent/javascriptreact.vim b/after/indent/javascriptreact.vim new file mode 100644 index 00000000..e423f0ed --- /dev/null +++ b/after/indent/javascriptreact.vim @@ -0,0 +1,5 @@ +if !exists('g:polyglot_disabled') || !(index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) + +source <sfile>:h/javascript.vim + +endif diff --git a/after/indent/typescript.vim b/after/indent/typescript.vim index b7f0d185..dd8ee271 100644 --- a/after/indent/typescript.vim +++ b/after/indent/typescript.vim @@ -26,7 +26,7 @@ if exists('s:did_indent') endif setlocal indentexpr=GetJsxIndent() -setlocal indentkeys=0{,0},0),0],0?,0\*,0\,,!^F,:,<:>,o,O,e,<>>,=*/ +setlocal indentkeys=0.,0{,0},0),0],0?,0\*,0\,,!^F,:,<:>,o,O,e,<>>,=*/ function! GetJsxIndent() return jsx_pretty#indent#get(function('GetTypescriptIndent')) diff --git a/after/indent/typescriptreact.vim b/after/indent/typescriptreact.vim new file mode 100644 index 00000000..931839b1 --- /dev/null +++ b/after/indent/typescriptreact.vim @@ -0,0 +1,5 @@ +if !exists('g:polyglot_disabled') || !(index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'typescript') != -1 || index(g:polyglot_disabled, 'jsx') != -1) + +source <sfile>:h/typescript.vim + +endif |