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.
我正在查看具有所有 erb 插值的遗留代码<%==......而且我以前从未使用过它。
<%==
它是干什么用的?它与 有什么不同<%=?
<%=
它是输出原始内容的简写。
见https://stackoverflow.com/a/5533614/2128691
<%== @content.body %> 完全一样 <%= raw @content.body %>
<%== @content.body %>
完全一样
<%= raw @content.body %>