Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何使用带有 angularjs 数据绑定 {{}} 的 Rails 模板 <%= %>。示例 <%= {{ dataConfess.confess }} %> 。我知道这是一个错误。这样做的正确方法是什么?
您可以使用字符串:
<%= "{{ dataConfess.confess }}" %>
渲染后它看起来像:
{{ dataConfess.confess }}