Skip to content

Svelte 5: behavior of svelte-ignore is different between Svelte 4 and Svelte 5 #11482

@baseballyama

Description

@baseballyama

Describe the bug

In Svelte 4, if we wrote <!-- svelte-ignore —>, warnings that occur on child elements were also ignored, but Svelte 5 is not.

Reproduction

Svelte 4: https://svelte.dev/repl/6e5aed69999a482cbd33c8370d33b05e?version=4.2.15
Svelte 5: https://svelte-5-preview.vercel.app/#H4sIAAAAAAAAE2WPwUrEMBBAfyWOF4XGuuKpxIL4A96NhGwzuw6mk5JMq0vpv0tbPXmceY83zAwniligeZuBfY_QwPMwQAVyGdahTBgFoYKSxtytGxNoai1bMVdaq51rOnPKqPzhcHGcHCcmFsy-E5rQiT8SB_yudiH6I0b34YvzpaSOvGBwXWLJKSqtt_h87b88iXrNqaeCdxlLihPePD7cLiu3YraM-ms_Wbi30L5E6j5NvbH2Vxz_WaYedzrX25nFsqnXv6CCPgU6EQZoJI-4vC8_ZPo62iMBAAA=

Logs

No response

System Info

System:
    OS: macOS 14.2.1
    CPU: (10) arm64 Apple M2 Pro
    Memory: 171.27 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.12.1 - ~/.nodenv/versions/20.12.1/bin/node
    Yarn: 1.22.19 - /usr/local/bin/yarn
    npm: 10.5.2 - ~/.nodenv/versions/20.12.1/bin/npm
    pnpm: 8.15.7 - ~/.nodenv/versions/20.12.1/bin/pnpm
    bun: 1.0.3 - ~/.bun/bin/bun
  Browsers:
    Chrome: 124.0.6367.119
    Edge: 124.0.2478.80
    Safari: 17.2.1
  npmPackages:
    svelte: ^5.0.0-next.112 => 5.0.0-next.123

Severity

annoyance

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions