diff --git a/test/js/samples/action-custom-event-handler/expected.js b/test/js/samples/action-custom-event-handler/expected.js index 3fad4fb8cc..917cbf6cb2 100644 --- a/test/js/samples/action-custom-event-handler/expected.js +++ b/test/js/samples/action-custom-event-handler/expected.js @@ -21,10 +21,10 @@ function create_fragment(ctx) { }, m(target, anchor) { insert(target, button, anchor); - foo_action = foo.call(null, button, ctx.foo_function) || ({}); + foo_action = foo.call(null, button, ctx[1]) || ({}); }, - p(changed, ctx) { - if (is_function(foo_action.update) && changed.bar) foo_action.update.call(null, ctx.foo_function); + p(ctx) { + if (is_function(foo_action.update)) foo_action.update.call(null, ctx[1]); }, i: noop, o: noop, @@ -40,7 +40,7 @@ function handleFoo(bar) { } function foo(node, callback) { - + } function instance($$self, $$props, $$invalidate) { @@ -48,10 +48,10 @@ function instance($$self, $$props, $$invalidate) { const foo_function = () => handleFoo(bar); $$self.$set = $$props => { - if ("bar" in $$props) $$invalidate("bar", bar = $$props.bar); + if ("bar" in $$props) $$invalidate(0, bar = $$props.bar); }; - return { bar, foo_function }; + return [bar, foo_function]; } class Component extends SvelteComponent { diff --git a/test/js/samples/bind-online/expected.js b/test/js/samples/bind-online/expected.js index d34e84330f..278d807001 100644 --- a/test/js/samples/bind-online/expected.js +++ b/test/js/samples/bind-online/expected.js @@ -11,13 +11,13 @@ import { function create_fragment(ctx) { let dispose; - add_render_callback(ctx.onlinestatuschanged); + add_render_callback(ctx[1]); return { c() { dispose = [ - listen(window, "online", ctx.onlinestatuschanged), - listen(window, "offline", ctx.onlinestatuschanged) + listen(window, "online", ctx[1]), + listen(window, "offline", ctx[1]) ]; }, m: noop, @@ -34,10 +34,10 @@ function instance($$self, $$props, $$invalidate) { let online; function onlinestatuschanged() { - $$invalidate("online", online = navigator.onLine); + $$invalidate(0, online = navigator.onLine); } - return { online, onlinestatuschanged }; + return [online, onlinestatuschanged]; } class Component extends SvelteComponent { diff --git a/test/js/samples/bind-open/expected.js b/test/js/samples/bind-open/expected.js index f7bede2b4e..f235b21f7b 100644 --- a/test/js/samples/bind-open/expected.js +++ b/test/js/samples/bind-open/expected.js @@ -21,16 +21,14 @@ function create_fragment(ctx) { details.innerHTML = `summarycontent `; - dispose = listen(details, "toggle", ctx.details_toggle_handler); + dispose = listen(details, "toggle", ctx[1]); }, m(target, anchor) { insert(target, details, anchor); - details.open = ctx.open; + details.open = ctx[0]; }, - p(changed, ctx) { - if (changed.open) { - details.open = ctx.open; - } + p(ctx) { + details.open = ctx[0]; }, i: noop, o: noop, @@ -45,15 +43,14 @@ function instance($$self, $$props, $$invalidate) { let { open } = $$props; function details_toggle_handler() { - open = this.open; - $$invalidate("open", open); + $$invalidate(0, open = this.open); } $$self.$set = $$props => { - if ("open" in $$props) $$invalidate("open", open = $$props.open); + if ("open" in $$props) $$invalidate(0, open = $$props.open); }; - return { open, details_toggle_handler }; + return [open, details_toggle_handler]; } class Component extends SvelteComponent {