开发者

Better syntax highlighting for js.erb files in Textmate

开发者 https://www.devze.com 2023-01-18 20:20 出处:网络
I\'d like Textmate to highlight Ruby syntax inside <% %> tags in *.js.erb files (like it does in *.html.erb files). Right now it looks like this:

I'd like Textmate to highlight Ruby syntax inside <% %> tags in *.js.erb files (like it does in *.html.erb files). Right now it looks like this:

Better syntax highlighting for js.erb files in Textmate

As you can see, everything within the quotes is treated like a regular JS string – an开发者_JAVA技巧noying.


I think the "HTML (Rails)" bundle in TextMate would define the syntax highlighting for what you're looking for, and what you're describing would probably be an enhancement to the plugin. I'd dig into the DrNic Ruby on Rails bundle (or email him for tips, he is friendly) to look for how you can add this functionality. I'm entirely sure this is the correct bundle, but DrNic has developed others and starting with asking him for help would be a good bet. You can google for his personal blog/contact details.

0

精彩评论

暂无评论...
验证码 换一张
取 消