Answer the question
In order to leave comments, you need to log in
Does it make sense to use the content_tag helper?
Hello! I asked myself the question, why is it needed at all and how to do it right.
I can write
content_tag : div, @page.content, class => 'content'
<div class='content'><%= @page.content %></div>
Answer the question
In order to leave comments, you need to log in
Depending on where the design is written. In view, you can also use a regular tag, but in a helper, content_tag and tag are more convenient
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question