Bug Tracker

Opened 13 years ago

Closed 12 years ago

Last modified 11 years ago

#5479 closed enhancement (fixed)

removeAttr: remove multiple attributes

Reported by: scottgonzalez Owned by: Rick Waldron
Priority: low Milestone: 1.7
Component: attributes Version: 1.5.2
Keywords: 1.7-discuss Cc:
Blocked by: Blocking:

Description

It would be nice if removeAttr() accepted multiple attributes. This could work exactly like removeClass() does.

Change History (29)

comment:1 Changed 13 years ago by dmethvin

Component: unfiledattributes

comment:2 Changed 12 years ago by Rick Waldron

Keywords: needsreview added
Milestone: 1.5
Owner: set to Rick Waldron
Priority: majorlow
Status: newassigned

Good suggestion

comment:3 Changed 12 years ago by dmethvin

Keywords: needsreview removed

comment:4 Changed 12 years ago by jitter

#7649 is a duplicate of this ticket.

comment:5 Changed 12 years ago by jitter

Version: 1.3.21.4.4

comment:7 Changed 12 years ago by petersendidit

Whats the reason this isn't getting landed?

comment:8 Changed 12 years ago by timmywil

Would we like to add this to attrhooks?

comment:9 Changed 12 years ago by timmywil

Milestone: 1.7
Version: 1.4.41.5.2

My guess is this will probably land with the enhancement on removeData in 1.7: #7323

comment:10 Changed 12 years ago by timmywil

#8221 is a duplicate of this ticket.

comment:11 Changed 12 years ago by john

Milestone: 1.71.next

We should consider this for 1.7.

comment:12 Changed 12 years ago by john

Keywords: 1.7-discuss added

Nominating ticket for 1.7 discussion.

comment:13 Changed 12 years ago by Rick Waldron

+1, Consistent with #7323

comment:14 Changed 12 years ago by jaubourg

+1, yes to API Symmetry

comment:15 Changed 12 years ago by ajpiano

+1, Deffo

comment:16 Changed 12 years ago by timmywil

+1, Yes, but possibly with an access-like function to dry up similar functions.

comment:17 Changed 12 years ago by danheberden

+1

comment:18 Changed 12 years ago by dmethvin

+1, An access-like function would be good here.

comment:19 Changed 12 years ago by john

+1, Obvious missing API.

comment:20 Changed 12 years ago by scottgonzalez

+1, obviously, I filed the ticket :-)

comment:21 Changed 12 years ago by addyosmani

+1

comment:22 Changed 12 years ago by jzaefferer

+1, one more feature I could take out of my validation plugin

comment:23 Changed 12 years ago by cowboy

+1, I like it, but should we do .removeAttr("foo bar") or .removeAttr("foo", "bar")?

comment:24 in reply to:  23 Changed 12 years ago by scottgonzalez

Replying to cowboy:

+1, I like it, but should we do .removeAttr("foo bar") or .removeAttr("foo", "bar")?

"foo bar", consistent with everything

comment:25 Changed 12 years ago by ajpiano

Milestone: 1.next1.7

comment:27 Changed 12 years ago by Rick Waldron

At this point, whatever, the first is out of date, but that can be fixed. The second is up-to-date, but has no tests and hasn't responded or updated with the tests I provided: ( https://github.com/rwldrn/jquery/commit/bece3a7ab2ae26947634ad57fb08390d55d209fc )

comment:28 Changed 12 years ago by Rick Waldron

Since no one has responded to my last comment about combining the efforts, I've gone ahead and done so myself.

Current: https://github.com/jquery/jquery/pull/492/

comment:29 Changed 12 years ago by Rick Waldron

Resolution: fixed
Status: assignedclosed

Landing pull request 492. 1.7 Remove multiple attributes (Symmetry with removeClass) Combines patches submitted by leeoniya, zertosh and my own tests. Fixes #5479.

More Details:

Note: See TracTickets for help on using tickets.