【发布时间】:2016-01-13 08:57:25
【问题描述】:
我试图把这个 html 翻译成 haml。我使用http://html2haml.herokuapp.com/ 和http://htmltohaml.com/ 没有成功。
<li class="nav-item btn-group" data-behavior="notifications" data-notifications='<%= render template: "notifications/index", formats: [:json] %>'>
</li>
他们给了我这两个:
%li.nav-item.btn-group{"data-behavior" => "notifications", "data-notifications" => render template: "notifications/index", formats: [:json]}
但我有一个 SyntaxError 运行这个。 有人可以帮我吗?
【问题讨论】:
-
@AndreyDeineko 谢谢,但我只需要翻译这一行而不是整个项目。
标签: html ruby-on-rails haml