-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
Documentation for how to configure templates in v3 #862
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Documentation for how to configure templates in v3 #862
Comments
Well, the intended way would be to write a plugin for that, and publish it. Your plugin can ask the user additional prompts as well as copy over its own templates, check the docs that we have so far: https://github.com/vuejs/vue-cli/blob/dev/docs/plugin-dev.md We will certainly extend and imrpove these, e.g. to explain in more detail how So the workflow for your users would be:
|
Thank you @LinusBorg, I'd briefly scanned the plugin dev page but hadn't noticed the I'll take a look at that page and see if I can get something working locally 👍 |
What problem does this feature solve?
In v2, it was easy to build a template that came with a custom index.html file and some default components. In v3 I'm not sure if this is possible, or if it is possible, how it is done.
I'm building a
vue-cli
template for my organisation and I'd like to benefit from the plugin based approach of v3, but also give my users something more than just the default HelloWorld components after they have runvue create
. I'd like to supply some components and also a customised app shell, so would need to alter the contents ofgenerator/template
(https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-service/generator/template) - I guess?Is this possible? It might be useful to document this either way as it will help users who wish to migrate from v2 to v3.
What does the proposed API look like?
Documentation change to either supply information on producing custom generator templates, or to specify that v2 should be used for this purpose.
The text was updated successfully, but these errors were encountered: