3 ms·
Combining Haml with jQuery Mobile makes it pretty much mandatory: #main_page{:"data-role" => 'page'}
by aaronbrethorst 16y ago
Combining Haml with jQuery Mobile makes it pretty much mandatory:
#main_page{:"data-role" => 'page'}
- nex3 16y agoHaml keys can be plain strings. #main_page{"data-role" => 'page'} `data-` attributes are also special-cased: #main_page{data: {role: 'page'}}
- aaronbrethorst 16y agoI did not know that. Thanks for the heads up, and thanks for Haml and Sass!
- snprbob86 16y agoYou can also use "HTML-style attributes" [1] #main_page(data-role='page') [1] http://haml-lang.com/docs/yardoc/file.HAML_REFERENCE.html#htmlstyle_attributes_ http://haml-lang.com/docs/yardoc/file.HAML_REFERENCE.html#ht...