29 lines
1018 B
VimL
29 lines
1018 B
VimL
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'vue') == -1
|
|
|
|
" Vim filetype plugin
|
|
" Language: Vue.js
|
|
" Maintainer: Eduardo San Martin Morote
|
|
" Author: Adriaan Zonnenberg
|
|
|
|
if exists('b:did_ftplugin')
|
|
finish
|
|
endif
|
|
|
|
runtime! ftplugin/html.vim
|
|
|
|
setlocal suffixesadd+=.vue
|
|
|
|
if !exists('g:no_plugin_maps') && !exists('g:no_vue_maps')
|
|
nnoremap <silent> <buffer> [[ :call search('^<\(template\<Bar>script\<Bar>style\)', 'bW')<CR>
|
|
nnoremap <silent> <buffer> ]] :call search('^<\(template\<Bar>script\<Bar>style\)', 'W')<CR>
|
|
nnoremap <silent> <buffer> [] :call search('^</\(template\<Bar>script\<Bar>style\)', 'bW')<CR>
|
|
nnoremap <silent> <buffer> ][ :call search('^</\(template\<Bar>script\<Bar>style\)', 'W')<CR>
|
|
endif
|
|
|
|
" Run only ESLint for Vue files by default.
|
|
" linters specifically for Vue can still be loaded.
|
|
let b:ale_linter_aliases = get(get(g:, 'ale_linter_aliases', {}), 'vue', ['vue', 'javascript'])
|
|
let b:ale_linters = get(get(g:, 'ale_linters', {}), 'vue', ['eslint', 'vls'])
|
|
|
|
endif
|