mirror of https://github.com/sveltejs/svelte
perf: treat `<img loading>` as a static element again (#18711)
Emits less code and skips two live DOM traversals per instance. `is_static_element` treats `<img>` with a `loading` attribute as non-static. That was added in #14237 so `RegularElement` could emit `$.handle_lazy_img(node_id)`, which needed a reference to the element. #15272 deleted `handle_lazy_img` (replaced by `importNode`) and removed the call site, but left this check behind. --------- Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com>pull/18714/head
parent
135f1ec004
commit
359413f512
@ -0,0 +1,5 @@
|
||||
---
|
||||
'svelte': patch
|
||||
---
|
||||
|
||||
perf: treat `<img loading>` as a static element again
|
||||
Loading…
Reference in new issue