sveltejs / kit

web development, streamlined
https://kit.svelte.dev
MIT License
18.6k stars 1.92k forks source link

enhanced:img should be considered a void element #12255

Open mquandalle opened 5 months ago

mquandalle commented 5 months ago

Describe the bug

Following https://github.com/sveltejs/svelte/issues/11052, svelte now warns on self closing tags for non void elements. This causes a warning when using <enhanced:img />, which is inconsistent with the usage of <img />

Reproduction

image

Logs

No response

System Info

System:
    OS: macOS 14.3.1
    CPU: (8) arm64 Apple M2
    Memory: 83.28 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 18.16.0 - ~/.nvm/versions/node/v18.16.0/bin/node
    Yarn: 1.22.19 - ~/.nvm/versions/node/v18.16.0/bin/yarn
    npm: 9.5.1 - ~/.nvm/versions/node/v18.16.0/bin/npm
    pnpm: 8.14.1 - ~/.nvm/versions/node/v18.16.0/bin/pnpm
    bun: 1.1.3 - ~/.bun/bin/bun
  Browsers:
    Brave Browser: 114.1.52.126
    Safari: 17.3.1
  npmPackages:
    @sveltejs/adapter-vercel: ^5.1.0 => 5.3.0 
    @sveltejs/enhanced-img: ^0.2.0 => 0.2.0 
    @sveltejs/kit: ^2.5.0 => 2.5.9 
    @sveltejs/pancake: ^0.0.18 => 0.0.18 
    @sveltejs/vite-plugin-svelte: ^3.0.2 => 3.1.0 
    svelte: next => 5.0.0-next.137 
    vite: ^5.1.0 => 5.2.11

Severity

annoyance

Additional Information

No response

mquandalle commented 5 months ago

Probably an issue with https://github.com/sveltejs/language-tools/issues, not SvelteKit

jasonlyu123 commented 5 months ago

Related to https://github.com/sveltejs/language-tools/issues/2321