Skip to content

Component & file names comment markup is missing in svelte v5Β #14952

@harshmandan

Description

@harshmandan

Describe the bug

In svelte v4, the markup in dev mode would contain the file name & components names in the html markup as comments. Here's a screenshot:
image

But in svelte v5, the markup now omits the file name & comment names in dev mode, making it hard to parse the markup in large apps.

image

Reproduction

For v4:
https://stackblitz.com/edit/sveltejs-kit-template-default-k8mk4s?file=package.json

For v5:
https://stackblitz.com/edit/sveltejs-kit-template-default-xkgpk8fk?file=package.json

Logs

No response

System Info

System:
    OS: macOS 15.2
    CPU: (8) arm64 Apple M1 Pro
    Memory: 123.53 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.11.0 - ~/.nvm/versions/node/v20.11.0/bin/node
    npm: 10.2.4 - ~/.nvm/versions/node/v20.11.0/bin/npm
    pnpm: 9.15.3 - ~/.nvm/versions/node/v20.11.0/bin/pnpm

Severity

blocking an upgrade

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