Sublime Text 3(Ruby on Rails& Haml)中多行代码的语法高亮问题

时间:2017-05-24 15:15:54

标签: ruby-on-rails sublimetext3 haml syntax-highlighting

当我在几行上分解我的代码时,我的html.haml视图中的语法突出显示失败:

实施例: 突出显示单行工作的语法:

  = link_to results_path(keyword), remote: true, rel: 'tooltip', title: 'Voir les résultats Google' do
    %i.icon-external-link

但是在多行上,语法高亮仅适用于第一行:

  = link_to results_path(keyword), remote: true,
      rel: 'tooltip', title: 'Voir les résultats Google' do
    %i.icon-external-link

what I get: no syntax highlighting on "child" lines

what I would expect: syntax highlighting even on child lines

以下是我安装的软件包,指的是语法高亮显示&代码显示:

  • ApplySyntax
  • Haml的
  • + Ruby on Rails片段

1 个答案:

答案 0 :(得分:4)

这个https://github.com/iRet/sublime-haml为我解决了这个问题(Sublime 3)。安装后,只需选择Ruby Haml(带语法选项的根列表)而不是Rails -> Ruby Haml