Open Cahllagerfeld opened 1 year ago
Do we want to handle this inside create-webstone-app, or do we want to have this as part of the cli for example
I would add it to create-webstone-app
, but only to convert a SvelteKit lib package into a Webstone plugin. I think we no longer have a concept of converting a SvelteKit app into a Webstone app, do we?
I see 3 use cases for create-webstone-app
:
1) To create a new app
2) To create a new plugin
3) To convert a SvelteKit lib package into a Webstone Plugins package.
If a user runs npm create webstone-app
without any --type
flag, we check if the current directory is an existing SvelteKit lib package and if so, ask the user if they want to convert it. We can determine that if the package.json
contains a package
script.
How would the signature of our create-webstone
function that we expose through code look like? Would it be a flag, or should the check be done automatically?
My first instinct is to make it a parameter. It's likely the easier approach and less magic happens from the eyes of the developer who wants to integrate it into their code.
Things to clarify:
create-webstone-app
, or do we want to have this as part of the cli for example