Angelmmiguel/material_icons

Helper not html_safe

kurtisnelson opened this issue · 6 comments

If you use the helper, it's output is not marked HTML safe.

Hello,

When you use the helper, it returns an instance of MaterialIcon model. When render it into the view, to_s method is called. This method use content_tag, a helper provided by ActionView. Returned string of this method is html_safe, as you can see in ActionView::Helpers::TagHelper line 137.

I have to use a double equals though.

What do you mean with double equals @kurtisnelson?

In slim, a == overrides html_safe and doesn't escape the string. If I use
=, I end up with HTML on the page.

On Tue, Oct 6, 2015, 17:19 Ángel M notifications@github.com wrote:

What do you mean with double equals @kurtisnelson
https://github.com/kurtisnelson?


Reply to this email directly or view it on GitHub
#4 (comment)
.

I still don't understand where do you use double equals and equals methods. They are different completely. Can you explain more your problem?

Please, add more info about variables you use, initialization of them... And a piece of code that show your problem.

Thanks!

I not received any update in this issue from ten days ago. I will close it. If you need more help on this issue or another, please reopen this or create a new one. Thanks!