For the sake of good looking code, is there some way to add a tab of spacing across the entire layout <%= yield %>
in Ruby on Rails? Here's what I mean:
THIS:
# layout.html.erb
<body>
<%= yield %>
</body>
PLUS THIS:
# page.html.erb
<h1>Test</h1>
<p>Hello, world!</p>
OUTPUTS:
<body>
<h1>Test</h1>
<p>Hello, world!</p>
</body>
WHAT I REALLY WANT TO OUTPUT:
<body>
<h1>Test</h1>
<p>Hello, World!</p>
</body>
I did some research and found that using a minus sign like <%= yield -%>
removes indentation, but I couldn't find a way to add it. Any ideas?