Skip to content

fix(package): remove transformed outputs when sources are deleted in watch mode - #17519

Draft
svelte-triage-bot[bot] wants to merge 1 commit into
mainfrom
triage/kit-17518-package-watch-unlink
Draft

svelte-triage-bot[bot] wants to merge 1 commit into
mainfrom
triage/kit-17518-package-watch-unlink

Conversation

@svelte-triage-bot

Copy link
Copy Markdown
Contributor
  • Watch creation uses normalized file.dest, but deletion used source file.name, leaving compiled JavaScript and custom-extension Svelte outputs behind.
  • Reuse the writer’s output mapping rather than special-casing TypeScript; retain incremental cleanup introduced in #4658 and preserved through #8922.
  • Keep chokidar rename handling (#16641) and unrelated output preservation (#13055) instead of rebuilding or wiping output on deletion.
  • Cover TypeScript/declaration removal, unchanged JavaScript/Svelte filenames, custom-extension directory renames, and empty-directory cleanup.

Fixes #17518

@pkg-svelte-dev

Copy link
Copy Markdown

Install the latest version of @sveltejs/kit from 26cc741:

pnpm add https://pkg.svelte.dev/@sveltejs/kit/c/26cc741518be003772b96099701173a8f5534c95

Open in pkg.svelte.dev: https://pkg.svelte.dev/repos/kit/pr/17519

Note

This PR is from a fork. A maintainer must approve approve each commit before it can be built and installed.

@changeset-bot

changeset-bot Bot commented Oct 22, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 26cc741

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@sveltejs/package Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

svelte-package watch mode leaves the compiled .js of a deleted .ts file in the output

0 participants