mirror of https://github.com/sveltejs/svelte
fix: improve compiler attribute validation logic (#12081)
prevent misidentification of bindings as delegatable event handlers if used outside event attribute Fixes #12074 --------- Co-authored-by: Rich Harris <rich.harris@vercel.com>pull/12085/head
parent
69ee547c21
commit
696a4b3dae
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
"svelte": patch
|
||||||
|
---
|
||||||
|
|
||||||
|
fix: prevent misidentification of bindings as delegatable event handlers if used outside event attribute
|
@ -0,0 +1,7 @@
|
|||||||
|
import { test } from '../../test';
|
||||||
|
|
||||||
|
export default test({
|
||||||
|
test() {
|
||||||
|
// Compiler shouldn't error
|
||||||
|
}
|
||||||
|
});
|
@ -0,0 +1,5 @@
|
|||||||
|
<script>
|
||||||
|
function f() {}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<input onchange={f}>{f}
|
Loading…
Reference in new issue