Closed mariomc closed 10 years ago
I'd say feature. I'm open to either I guess. I rarely use the get-all syntax except for inspection. To me it makes sense for the keys to be exactly like you set them (unlike how jQuery camelCases them).
i would never expect that to happen. data is data and should be retrieved the same way you set them, just like all document stores. the fact that jQuery does this is bizarre. sorry that this is a no-fix, hope this doesn't deter your development
The data method doesn't camelize hyphen separated properties.
If you, for instance, call bonzo(document.body).data('foo-bar', 'baz'), the result from bonzo(document.body).data() returns { 'foo-bar' : 'baz' } instead of { 'fooBar' : 'baz' }.
Is this a bug or a feature?