0

Basically I am trying to get this output in Rails and Slim:

<a href="/some/link">my<strong>name</strong></a>

This is what I have so far:

= link_to 'my<strong>name</strong>', controller: :pages, action: :home

Obviously it outputs:

my<strong>name</strong> on the page instead of interpreting the strong tags. Any thoughts?

rctneil
  • 7,016
  • 10
  • 40
  • 83

1 Answers1

1

You need to Rails that the string is safe :

= link_to 'my<strong...>'.html_safe
Ven
  • 19,015
  • 2
  • 41
  • 61