mirror of https://github.com/sveltejs/svelte
fix: don't transform references of function declarations in legacy mode (#17431)
parent
044dce9da5
commit
ac7c7646bc
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
'svelte': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
fix: don't transform references of function declarations in legacy mode
|
||||||
@ -0,0 +1,7 @@
|
|||||||
|
import { test } from '../../test';
|
||||||
|
|
||||||
|
export default test({
|
||||||
|
async test({ assert, target }) {
|
||||||
|
assert.htmlEqual(target.innerHTML, `<input>`);
|
||||||
|
}
|
||||||
|
});
|
||||||
@ -0,0 +1,11 @@
|
|||||||
|
<script>
|
||||||
|
$: items = [{ value: 'hello' }];
|
||||||
|
|
||||||
|
function fn(value) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
{#each items.filter(fn) as item}
|
||||||
|
<input bind:value={item.value} />
|
||||||
|
{/each}
|
||||||
Loading…
Reference in new issue