Skip to content Skip to sidebar Skip to footer

Can't Modify CustomEvent Data

I need to fire a custom event each time when clicked on div with different data attached. Here is a simplified variant of my code (JSFiddle):
Copy

Fiddle

Or you would need to init the custom Event each time to set the details property like this:

arguments.callee.event.initCustomEvent("selectItem", true, true, event_data);

and details property will have new updated value each time the event is dispacthed.

Demo


Post a Comment for "Can't Modify CustomEvent Data"