Element.hasAttribute('data-thing')
Element.getAttribute('data-thing')
Element.setAttribute('data-thing', '...')
Much more clear what I'm doing without the awkward translating when I inevitably have to inspect/debug in the DOM.
Element.hasAttribute('data-thing')
Element.getAttribute('data-thing')
Element.setAttribute('data-thing', '...')
Much more clear what I'm doing without the awkward translating when I inevitably have to inspect/debug in the DOM.