Skip to main content

Bug Tracker

Side navigation

#10150 closed bug (worksforme)

Opened August 27, 2011 10:35AM UTC

Closed August 27, 2011 06:48PM UTC

Last modified September 03, 2011 02:46PM UTC

jQuery.fn.data parses data attributes incorrectly

Reported by: grimen@gmail.com Owned by: rwaldron
Priority: low Milestone: None
Component: data Version: 1.6.2
Keywords: Cc:
Blocked by: Blocking:
Description

See this screenshot of my console output (Chrome 13):

https://skitch.com/grimen/fweb4/developer-tools-http-localhost-3000-admin-tagged-images-debug

I get mixed "CamelCase" with "snake_case" here - I cannot consider this anything else than a bug, neither the dev aside of me. :)

(EDIT: Sorry about that, I was on my mobile and must've slipped and deleted this)

Attachments (0)
Change History (4)

Changed August 27, 2011 02:47PM UTC by rwaldron comment:1

component: unfileddata
description: See this screenshot of my console output (Chrome 13): \ \ https://skitch.com/grimen/fweb4/developer-tools-http-localhost-3000-admin-tagged-images-debug \ \ I get mixed "CamelCase" with "snake_case" here - I cannot consider this anything else than a bug, neither the dev aside of me. :)See this screenshot of my console output (Chrome 13): \ \ \ \ I get mixed "CamelCase" with "snake_case" here - I cannot consider this anything else than a bug, neither the dev aside of me. :)
owner: → rwaldron
status: newassigned

Changed August 27, 2011 06:40PM UTC by rwaldron comment:2

description: See this screenshot of my console output (Chrome 13): \ \ \ \ I get mixed "CamelCase" with "snake_case" here - I cannot consider this anything else than a bug, neither the dev aside of me. :)See this screenshot of my console output (Chrome 13): \ \ https://skitch.com/grimen/fweb4/developer-tools-http-localhost-3000-admin-tagged-images-debug \ \ I get mixed "CamelCase" with "snake_case" here - I cannot consider this anything else than a bug, neither the dev aside of me. :) \ \ \ (EDIT: Sorry about that, I was on my mobile and must've slipped and deleted this)

Changed August 27, 2011 06:48PM UTC by rwaldron comment:3

priority: undecidedlow
resolution: → worksforme
status: assignedclosed

jQuery's behaviour matches the intended and expected behaviour of native "dataset" as closely as possible, as seen here:

http://gyazo.com/0cc2d7f4553a1f4a577b667e46b26eff.png

http://jsfiddle.net/rwaldron/Ee8Md/

Changed September 03, 2011 02:46PM UTC by grimen@gmail.com comment:4

Thanks for the explanation and samples - appreciated response so quick.

So my view of jQuery always been that it's a layer on top of native (flawed) JS/DOM implementation fixing broken stuff and add compatability. This case is a obvious broken behavior in the native "experience" - it would be hard to find anyone find any good/valid arguments for not fixing this. This makes the wonder what the vision of jQuery really is and also "write less, do more" slogan got more misleading?