Skip to content

Commit a37130d

Browse files
committed
Drop JavaScript highlighting
All this just to highlight $ and jQuery? Not worth it.
1 parent cac25b5 commit a37130d

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

autoload/rails.vim

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3663,7 +3663,6 @@ call s:add_methods('app', ['user_classes','user_assertions'])
36633663
function! rails#buffer_syntax()
36643664
if !exists("g:rails_no_syntax")
36653665
let buffer = rails#buffer()
3666-
let javascript_functions = "$ jQuery"
36673666
let keywords = split(join(buffer.projected('keywords'), ' '))
36683667
let special = filter(copy(keywords), 'v:val =~# ''^\h\k*[?!]$''')
36693668
let regular = filter(copy(keywords), 'v:val =~# ''^\h\k*$''')
@@ -3791,9 +3790,6 @@ function! rails#buffer_syntax()
37913790
endif
37923791
exe 'syn keyword '.&syntax.'RailsRenderMethod render contained containedin=@'.&syntax.'RailsRegions'
37933792
exe 'syn case match'
3794-
set isk+=$
3795-
exe 'syn keyword javascriptRailsFunction contained '.javascript_functions
3796-
exe 'syn cluster htmlJavaScript add=javascriptRailsFunction'
37973793
elseif &syntax == "yaml"
37983794
syn case match
37993795
unlet! b:current_syntax
@@ -3807,16 +3803,6 @@ function! rails#buffer_syntax()
38073803
syn region yamlRailsComment matchgroup=yamlRailsDelimiter start="<%#" end="%>" contains=rubyTodo,@Spell containedin=ALLBUT,@yamlRailsRegions,yamlRailsComment keepend
38083804
syn match yamlRailsMethod '\.\@<!\<\(h\|html_escape\|u\|url_encode\)\>' contained containedin=@yamlRailsRegions
38093805
let b:current_syntax = "yaml"
3810-
elseif &syntax == "html"
3811-
syn case match
3812-
set isk+=$
3813-
exe "syn keyword javascriptRailsFunction contained ".javascript_functions
3814-
syn cluster htmlJavaScript add=javascriptRailsFunction
3815-
elseif &syntax == "javascript" || &syntax == "coffee"
3816-
" The syntax file included with Vim incorrectly sets syn case ignore.
3817-
syn case match
3818-
set isk+=$
3819-
exe "syn keyword javascriptRailsFunction ".javascript_functions
38203806

38213807
elseif &syntax == "scss" || &syntax == "sass"
38223808
syn match sassFunction "\<\%(\%(asset\|image\|font\|video\|audio\|javascript\|stylesheet\)-\%(url\|path\)\)\>(\@=" contained

0 commit comments

Comments
 (0)