feat(cli): sv create --from-playground

#662

Closing issue

Pull request

Draft
M
manuel3108
Aug 3, 2025, 4:54 PM

Closes #602

You can now run pnpx https://pkg.pr.new/sveltejs/cli/sv@662 create --from-playground=https://svelte.dev/playground/hello-world. This is currently doing more or less the same the stuff the Download App button in the playground is doing. Apart from that, you can choose additional addons, ts vs js and install deps. External dependencies are auto-detected and installed into the package.json

Todos:

  • more (manual) testing
  • consider if we should prompt the user before installing external dependencies on the local computer
  • handle svelte-?version= parameter from the playground url
  • Feedback from dominikg: one thing to remember is that this is untrusted input basically, the playground could reference malicious packages, so installation with --ignore-scripts and making users aware that they have to check the content beforehand would be good.

Info

Assignees None
Reviewers None
Labels None
Milestone None