What's the best way to get data attribute JavaScript values from an element? or How do I properly use

18 Replies, 1026 Views

To get data attribute javascript values, I switch between `dataset` and `getAttribute()` depending on mood lol.

But seriously, `dataset` is cleaner for multiple attributes.

If you’re stuck, paste your code here—might just be a typo!

Messages In This Thread



Users browsing this thread: 1 Guest(s)