13
rated 0 times
[
16]
[
3]
/ answers: 1 / hits: 32176
/ 12 Years ago, tue, august 7, 2012, 12:00:00
I'm writing a jQuery plugin and using .on
and .trigger
as my pub/sub system. However, I want to trigger multiple events in different scenarios.
Is this possible to do as one string, like the .on
method?
Goal:
$this.trigger(success next etc); // doesn't work
Current solution:
$this
.trigger(success)
.trigger(next)
.trigger(etc); // works, triggers all three events
Any suggestions?
More From » jquery