You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/js/samples/collapses-text-around-comments/expected.js

64 lines
1.1 KiB

/* generated by Svelte vX.Y.Z */
import {
SvelteComponent,
append,
append_styles,
attr,
detach,
element,
init,
insert,
noop,
safe_not_equal,
set_data,
text
} from "svelte/internal";
function add_css(target) {
append_styles(target, "svelte-1a7i8ec", "p.svelte-1a7i8ec{color:red}");
}
function create_fragment(ctx) {
let p;
let t;
return {
c() {
p = element("p");
t = text(/*foo*/ ctx[0]);
attr(p, "class", "svelte-1a7i8ec");
},
m(target, anchor) {
insert(target, p, anchor);
append(p, t);
},
p(ctx, [dirty]) {
if (dirty & /*foo*/ 1) set_data(t, /*foo*/ ctx[0]);
},
i: noop,
o: noop,
d(detaching) {
if (detaching) detach(p);
}
};
}
function instance($$self, $$props, $$invalidate) {
let { foo = 42 } = $$props;
$$self.$$set = $$props => {
if ('foo' in $$props) $$invalidate(0, foo = $$props.foo);
};
return [foo];
}
class Component extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance, create_fragment, safe_not_equal, { foo: 0 }, add_css);
}
}
export default Component;