And the "let her speak please" happens just after 1:05: https://youtu.be/Er7qPv8jsZo?t=3928
16 karma · joined February 23, 2011
elem.data('foo', { 'a':1, 'b':2 });
elem.data('foo'); // Returns the object
Is certainly more desirable than: elem.attr('foo', { 'a':1, 'b':2 });
elem.attr('foo'); // Returns "[object Object]"That's the key advantage as I see it. If I'm scraping something it's often in a hurry and I just want it done. Not having to internalise a new API is a significant win in that respect.