Closed chicoxyzzy closed 2 months ago
@chicoxyzzy and I chatted, we think the right course of action here is to have a default template repository where we host templates in directories with naming conventions like [lang]-...
.
A great UX would be for dispatch init --help
to retrieve the list of templates available from the default repository.
We talked with @chriso and decided that we can skip the implementation of third-party templates for now. We will start with static templates and revisit third-party templates if the need for dynamic generation arises, as otherwise, people can simply use git clone
. At the same time, dynamic generation can be difficult to maintain and might lead to breaking changes. It is probably worth adding only if there is a need to add, for example, configuration files using additional flags for dispatch init
or some other similar features.
I want to propose a new
dispatch init
command that can help create a simple templates.Suggested syntax
[template]
Based on experience, it's usually hard to maintain templates that are coupled to or hardly integrated into the tool code base. I'd propose to use patterns like
author/repo
on GH (see community template in thecreate vite
repo in the list below).[options]
TBD. One of possible options could be
--local-dev
or something like this to create.env
file for the local development.Projects to take inspiration from:
create vite
— template generator for frontend applicationsyeoman
— "general purpose" template generatorto bee updated