I think it would be beneficial to introduce some layouts here.

You can the render the erb template like so:
`erb :root, layout: default`
and omit `head`, `body` and `html` tags.