vendredi 8 mai 2015

HAML: interpolate ruby variable for data attribute?

In a .html.haml file, I have a button:

%button{:data=>{'foo'=> @bar}, type:'button', 'id'=>'confirmBtn'} Confirm

However, the data attribute is not picking up anything. What is the proper way to interpolate ruby variables in this case?

Aucun commentaire:

Enregistrer un commentaire