Skip to content

chore(sv): refactor old code (WIP) - #1319

Draft
sacrosanctic wants to merge 2 commits into
sveltejs:version-1from
sacrosanctic:refactor-create
Draft

sacrosanctic wants to merge 2 commits into
sveltejs:version-1from
sacrosanctic:refactor-create

Conversation

@sacrosanctic

@sacrosanctic sacrosanctic commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Closes #956

Description

This is WIP, will be chipping away at this slowly. I wanted to use the CI and maintainers can take a peek to guide the direction.

The goal is the write code that effects shared and templates.

Checklist

  • Update snapshots (if applicable)
  • Add a changeset (if applicable)
  • Allow maintainers to edit this PR
  • I care about what I'm doing, no matter the tool I use (Notepad, Sublime, VSCode, AI...)

@pkg-svelte-dev

pkg-svelte-dev Bot commented Sep 9, 2026

Copy link
Copy Markdown

Install the latest version of sv from f453f56:

pnx https://pkg.svelte.dev/sv/c/f453f5657950b6416b8e09d15df6b09abd9dc711 create

Open in pkg.svelte.dev: https://pkg.svelte.dev/repos/cli/pr/1319

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 Sep 9, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: f453f56

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

@manuel3108

Copy link
Copy Markdown
Member

Hey!
can you potentially layout a bit more of what you are planning to do? The current PR does not really reveal anything.
I do completely agree that the create code in this repo is the worst one that is remaining, now that we get rid of the old migrate. And given that the migrations use the same sv.file api and stuff i do think it would feel natural to do the something similar for create and the different create templates. But migrations are not exactly an addon they just use a similar api.

Something similar should work for create I think, but I would prefer if we would discuss it first, before you start running in one direction. Do you have any concrete ideas how you would like to implement this?

Or did I misunderstand you and are you trying to do something completely different here?

@manuel3108 manuel3108 added the needs-addon-integration-tests Run the addon integration test suite label Sep 20, 2026
@sacrosanctic

Copy link
Copy Markdown
Contributor Author

No concrete plans yet, just feeling it out. My original idea was some sort of internal add-on. migrate might be a better mental model.

Everything is really tangled together so it's hard to make atomic changes. I might start with rewriting the template construction logic first. As it has a lot of baggage of wanting them to be running projects.

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

Labels

needs-addon-integration-tests Run the addon integration test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sv create as internal addon

2 participants