Activity
Dennis Hackethal addressed criticism #1984.
#1984·Dennis HackethalOP, about 1 year agoHiccdown should have support for ids and class names in the tag symbol. Like Hiccup.
ruby[:'div#my-id.my-class.another-class']# => <div id="my-id" class="my-class another-class"></div>It should also allow mixing:
ruby[:'div#my-id.my-class.another-class', {id: 'override', class: 'additive'}]# => <div id="override" class="my-class another-class additive"></div>In other words, the id from the hash would override the id from the symbol, and the class from the hash would be added to the classes from the symbol.
Done as of 3a304be, to be released in version 1.6.0, as described here. The id and classes can come in any order after the tag name, and two ids in one tag raise ArgumentError.