diff --git a/syntax/javascript.vim b/syntax/javascript.vim index 3bdb39a6..4ca08ecd 100644 --- a/syntax/javascript.vim +++ b/syntax/javascript.vim @@ -215,7 +215,7 @@ syntax match jsArrowFuncArgs /([^()]*)\s*\(=>\)\@=/ skipempty skipwhite conta syntax keyword jsClassKeywords extends class contained syntax match jsClassNoise /\./ contained syntax keyword jsClassMethodDefinitions get set static contained nextgroup=jsFuncName skipwhite skipempty -syntax match jsClassDefinition /class [a-zA-Z_$][0-9a-zA-Z_$ \n.]*/ contains=jsClassKeywords,jsClassNoise nextgroup=jsClassBlock skipwhite skipempty +syntax match jsClassDefinition /class\%( [a-zA-Z_$][0-9a-zA-Z_$ \n.]*\)*/ contains=jsClassKeywords,jsClassNoise nextgroup=jsClassBlock skipwhite skipempty " Define the default highlighting. " For version 5.7 and earlier: only when not done already