Merge pull request #1558 from sveltejs/revert-1557-1553-return-from-custom-event-handler

Revert "Fix for #1553"
pull/1572/head
Rich Harris 7 years ago committed by GitHub
commit 685a36f2b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -67,12 +67,12 @@ export default class EventHandler extends Node {
compiler.code.overwrite(
this.insertionPoint,
this.insertionPoint + 1,
`return ${component}.store.`
`${component}.store.`
);
} else {
compiler.code.prependRight(
this.insertionPoint,
`return ${component}.`
`${component}.`
);
}
}

@ -146,7 +146,7 @@ function create_main_fragment(component, ctx) {
button = createElement("button");
button.textContent = "foo";
foo_handler = foo.call(component, button, function(event) {
return component.foo( ctx.bar );
component.foo( ctx.bar );
});
},

@ -19,7 +19,7 @@ function create_main_fragment(component, ctx) {
button = createElement("button");
button.textContent = "foo";
foo_handler = foo.call(component, button, function(event) {
return component.foo( ctx.bar );
component.foo( ctx.bar );
});
},

Loading…
Cancel
Save