Fixed docs for trigger, describing the second argument.
This commit is contained in:
parent
de4e28e1ba
commit
43f235f425
1 changed files with 11 additions and 1 deletions
|
@ -313,9 +313,19 @@ jQuery.fn.extend({
|
||||||
* @before <p click="alert('hello')">Hello</p>
|
* @before <p click="alert('hello')">Hello</p>
|
||||||
* @result alert('hello')
|
* @result alert('hello')
|
||||||
*
|
*
|
||||||
|
* @example $("p").click(function(event, a, b) {
|
||||||
|
* // when a normal click fires, a and b are undefined
|
||||||
|
* // for a trigger like below a refers too "foo" and b refers to "bar"
|
||||||
|
* }).trigger("click", ["foo", "bar"]);
|
||||||
|
* @desc Example of how to pass arbitrary to an event
|
||||||
|
*
|
||||||
|
* @before <p click="alert('hello')">Hello</p>
|
||||||
|
* @result alert('hello')
|
||||||
|
*
|
||||||
* @name trigger
|
* @name trigger
|
||||||
* @type jQuery
|
* @type jQuery
|
||||||
* @param String type An event type to trigger.
|
* @param String type An event type to trigger.
|
||||||
|
* @param Array data (optional) Additional data to pass as arguments (after the event object) to the event handler
|
||||||
* @cat Events
|
* @cat Events
|
||||||
*/
|
*/
|
||||||
trigger: function( type, data ) {
|
trigger: function( type, data ) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue