Bug Tracker

Modify

Ticket #5448 (closed feature: invalid)

Opened 4 years ago

Last modified 4 years ago

Deep namespaced event's are being sorted

Reported by: corey.hart Owned by: brandon
Priority: minor Milestone: 1.4
Component: event Version: 1.3.2
Keywords: namespaced events Cc:
Blocking: Blocked by:

Description

All namespaced event's get sorted when they are stored/called. I've got a test page attached, but the following code snippet should suffice:

$(document).ready(function(){

$(document)

.bind('namespace.a.b', function(){

console.log('Called a.b');

}) .bind('namespace.b.a', function(){

console.log('Called b.a');

});

Shows 2 events, both with type a.b

console.log($(document).data('events'));

console.group('a.b');

$(document).trigger('namespace.a.b'); Should only trigger a.b

console.groupEnd();

console.group('b.a');

$(document).trigger('namespace.b.a'); Should only trigger b.a

console.groupEnd();

});

Attachments

namespace.html Download (649 bytes) - added by corey.hart 4 years ago.
Test Page

Change History

Changed 4 years ago by corey.hart

Test Page

comment:1 Changed 4 years ago by scott.gonzalez

  • Status changed from new to closed
  • Resolution set to invalid

jQuery doesn't have deep namespacing, it has multiple namespacing. "namespace.a.b" is the same as "namespace.a namespace.b".

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.