Skip to content

jQuery.fn.data() and data-* attribute name restrictions #383

Open
@rwaldron

Description

@rwaldron

http://bugs.jquery.com/ticket/14376

jQuery.fn.data() will not work data-* attributes in the very specific case where an attribute has been named with multiple words and any of the words after the first word (not including data-) begin with a digit.

Example:

<div data-foo-42></div>

However, these work just fine:

<div data-42></div>
<div data-foo42></div>

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions