mirror of https://github.com/sveltejs/svelte
parent
b8d15135cf
commit
8f152de6dc
@ -0,0 +1,5 @@
|
||||
---
|
||||
'svelte': patch
|
||||
---
|
||||
|
||||
fix: falsy attachments on components
|
@ -0,0 +1,5 @@
|
||||
<script>
|
||||
let props = $props();
|
||||
</script>
|
||||
|
||||
<div {...props}></div>
|
@ -0,0 +1,5 @@
|
||||
import { test } from '../../test';
|
||||
|
||||
export default test({
|
||||
test() {}
|
||||
});
|
@ -0,0 +1,13 @@
|
||||
<script>
|
||||
import Child from './Child.svelte';
|
||||
|
||||
function attachment(){
|
||||
console.log("up");
|
||||
}
|
||||
|
||||
let enabled = $state(false);
|
||||
</script>
|
||||
|
||||
<button onclick={() => enabled = !enabled}></button>
|
||||
|
||||
<Child {@attach enabled && attachment} />
|
Loading…
Reference in new issue