aria-* and data-* attributes
rstacruz opened this issue · 1 comments
rstacruz commented
It seems attributes with dashes are being ignored.
var h = require('virtual-dom/h')
var createElement = require('virtual-dom/create-element')
tree = h('div', { 'aria-label': 'hello', 'data-foo': 'world' })
div = createElement(tree)
div.outerHTML //=> "<div></div>"
Any clue how I can make this work?
rstacruz commented
ah, it seems the right way to do it is:
h('div', { attributes: { 'aria-label': 'hello' } })