mirror of
https://github.com/sheerun/vim-polyglot.git
synced 2025-11-10 12:33:51 -05:00
Update
This commit is contained in:
@@ -4,7 +4,7 @@ if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'qml') == -1
|
||||
" Language: QML
|
||||
" Author: Robert Kieffer
|
||||
" URL:
|
||||
" Last Change: 2010-03-27 (Happy Birthday, Dash!)
|
||||
" Last Change: 2017-10-27
|
||||
"
|
||||
" Improved JavaScript indent script.
|
||||
|
||||
@@ -22,10 +22,10 @@ if exists("*GetJsIndent")
|
||||
finish
|
||||
endif
|
||||
|
||||
" Clean up a line of code by removing trailing '//' comments, and trimming
|
||||
" Clean up a line of code by removing trailing '//' and '/* */' comments, and trimming
|
||||
" whitespace
|
||||
function! Trim(line)
|
||||
return substitute(substitute(a:line, '// .*', '', ''), '^\s*\|\s*$', '', 'g')
|
||||
return substitute(substitute(substitute(a:line, '// .*', '', ''), '/\* .* \*/', '', ''), '^\s*\|\s*$', '', 'g')
|
||||
endfunction
|
||||
|
||||
function! GetJsIndent()
|
||||
|
||||
Reference in New Issue
Block a user