Where is Ruby's ERB format “officially” defined?

天大地大妈咪最大 提交于 2019-12-03 10:56:16

erb was developed by Masatoshi Seki as a Ruby implementation of eRuby, so its specification almost follows that of eRuby. One difference the author mentions is:

% cat hello.erb
Hello, <% print "World" %>.

% eruby hello.erb
Hello, World.

% erb hello.erb
WorldHello, .

in which case you can do:

% cat hello2.erb
Hello, <%= "World" %>.

% eruby hello2.erb 
Hello, World.

% erb hello2.erb
Hello, World.

to let them work the same way.

Here is an explanation about it by the author, and here and here are documentation written by the author.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!