开发者

Find how many yields and their names

开发者 https://www.devze.com 2023-01-22 11:17 出处:网络
Is there a way in Rails to find out how many yields have been defined in a layout along with their corresponding n开发者_运维问答ames?grep -c yield < layout.html.erb

Is there a way in Rails to find out how many yields have been defined in a layout along with their corresponding n开发者_运维问答ames?


grep -c yield < layout.html.erb

That should get you the count you're looking for.


or ack "yield" app/views/layouts/. See Ack - Better thanGrep

0

精彩评论

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