Skip to main content

Bug Tracker

Side navigation

#13854 closed feature (wontfix)

Opened May 04, 2013 09:20PM UTC

Closed May 06, 2013 04:20PM UTC

Prefixing eventnames could be done by jQuery

Reported by: bfanger@gmail.com Owned by:
Priority: low Milestone: None
Component: event Version: 1.9.1
Keywords: Cc:
Blocked by: Blocking:
Description

I would like to write:

$el.bind('transitionend', function () {
    // do-stuff
});

Instead of:

$el.bind('webkitTransitionEnd transitionend msTransitionEnd oTransitionEnd', function () {
    // do-stuff
});

Or this http://jsfiddle.net/rGECn/2/

Attachments (0)
Change History (4)

Changed May 05, 2013 03:36AM UTC by timmywil comment:1

component: unfiledevent
priority: undecidedlow
status: newopen

Very nice idea, but I'm not sure the cost/benefit ratio is low enough.

Firstly, judging from webkit's list of prefixed APIs, there are only about 4-6 events that benefit from such a shortcut. The one named here (transitionend), 3 CSS animation events, and possibly speech recognition.

Secondly, we could probably reuse some of the CSS vender prefix code, but I imagine there wouldn't be as much overlap as we'd like (due not only to firefox's lack of a prefix with these events, but also our determination to keep the css module independent so it can be excluded).

I'll leave it open for discussion.

Changed May 05, 2013 02:32PM UTC by dmethvin comment:2

Technically I suppose the MSPointer* events would also qualify here, but for those it's extremely likely that the semantics will be changing before it's sanctified in a standard. If it was just a case of changing the name that would be one thing, that's basically what happened with CSS properties. But for events I think it's important for developers to realize they're working with pre-release features.

The W3C and browser makers have realized their mistake and Chrome/Blink has already committed to avoiding new prefixed features that are available by default. At this point we're just waiting for the old mistakes to die.

Changed May 05, 2013 08:24PM UTC by scottgonzalez comment:3

I think the correct implementation of this would be special events, but I don't think we should ship anything in core.

Changed May 06, 2013 04:20PM UTC by timmywil comment:4

resolution: → wontfix
status: openclosed