pseudo code

pull/4142/head
Pontus Lundin 6 years ago committed by GitHub
parent a9065d4120
commit f2eb632bc9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -28,6 +28,8 @@ export function onDestroy(fn) {
}
export function createEventDispatcher() {
// is compile target customElement?
// always dispatch!
const component = get_current_component();
return (type: string, detail?: any) => {
@ -61,4 +63,4 @@ export function bubble(component, event) {
if (callbacks) {
callbacks.slice().forEach(fn => fn(event));
}
}
}

Loading…
Cancel
Save