vim-polyglot/after/ftplugin/jsx.vim
2019-03-04 09:28:35 +01:00

24 lines
688 B
VimL

if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'jsx') != -1
finish
endif
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Vim ftplugin file
"
" Language: JSX (JavaScript)
" Maintainer: Max Wang <mxawng@gmail.com>
"
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" modified from html.vim
if exists("loaded_matchit")
let b:match_ignorecase = 0
let s:jsx_match_words = '(:),\[:\],{:},<:>,' .
\ '<\@<=\([^/][^ \t>]*\)[^>]*\%(/\@<!>\|$\):<\@<=/\1>'
let b:match_words = exists('b:match_words')
\ ? b:match_words . ',' . s:jsx_match_words
\ : s:jsx_match_words
endif
setlocal suffixesadd+=.jsx