From 2a7dc49baabe7c4ac8779caf372cb5f698bb041b Mon Sep 17 00:00:00 2001 From: bounceme Date: Tue, 10 May 2016 10:25:53 -0700 Subject: [PATCH 1/2] Update javascript.vim --- indent/javascript.vim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indent/javascript.vim b/indent/javascript.vim index 808bcb95..dfb163cd 100644 --- a/indent/javascript.vim +++ b/indent/javascript.vim @@ -44,7 +44,7 @@ endif let s:js_keywords = '^\s*\(break\|catch\|const\|continue\|debugger\|delete\|do\|else\|finally\|for\|function\|if\|in\|instanceof\|let\|new\|return\|switch\|this\|throw\|try\|typeof\|var\|void\|while\|with\)' let s:expr_case = '^\s*\(case\s\+[^\:]*\|default\)\s*:\s*' " Regex of syntax group names that are or delimit string or are comments. -let s:syng_strcom = '\%(string\|regex\|comment\|template\)\c' +let s:syng_strcom = '\%(string\|regex\|comment\|templates\)\c' " Regex of syntax group names that are or delimit template strings let s:syng_template = 'template\c' @@ -347,7 +347,7 @@ function GetJavascriptIndent() endif " single opening bracket will assume you want a c style of indenting - if s:Match(v:lnum, '^\s*{' . s:line_term) && s:GetMSL(v:lnum,0) == v:lnum + if s:Match(v:lnum, '^\s*{' . s:line_term) return cindent(v:lnum) endif From 85a4357da8ec0e49c91f9761fd7e793fa847f543 Mon Sep 17 00:00:00 2001 From: bounceme Date: Tue, 10 May 2016 13:41:14 -0700 Subject: [PATCH 2/2] Update javascript.vim --- indent/javascript.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indent/javascript.vim b/indent/javascript.vim index dfb163cd..f1979fae 100644 --- a/indent/javascript.vim +++ b/indent/javascript.vim @@ -44,7 +44,7 @@ endif let s:js_keywords = '^\s*\(break\|catch\|const\|continue\|debugger\|delete\|do\|else\|finally\|for\|function\|if\|in\|instanceof\|let\|new\|return\|switch\|this\|throw\|try\|typeof\|var\|void\|while\|with\)' let s:expr_case = '^\s*\(case\s\+[^\:]*\|default\)\s*:\s*' " Regex of syntax group names that are or delimit string or are comments. -let s:syng_strcom = '\%(string\|regex\|comment\|templates\)\c' +let s:syng_strcom = '\%(string\|regex\|comment\|template\)\c' " Regex of syntax group names that are or delimit template strings let s:syng_template = 'template\c'