mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-07 06:57:02 +08:00
code with words
This commit is contained in:
@ -17,7 +17,9 @@
|
||||
// Some convenient top-level event functions
|
||||
|
||||
framework.trigger = function(type, data) {
|
||||
window.dispatchEvent(new CustomEvent(type, data));
|
||||
window.dispatchEvent(new CustomEvent(type, {
|
||||
detail: data
|
||||
}));
|
||||
};
|
||||
|
||||
framework.on = function(type, callback, element) {
|
||||
@ -94,4 +96,5 @@
|
||||
window.addEventListener('touchend', _touchEnd);
|
||||
window.addEventListener('click', _click);
|
||||
window.addEventListener('popstate', _popstate);
|
||||
})(this, document, this.FM = this.FM || {});
|
||||
|
||||
})(this, document, FM = this.FM || {});
|
||||
|
||||
Reference in New Issue
Block a user