feature: `kit new --ui-only`
Opened this issue · 1 comments
Is your feature request related to a problem? Please describe.
for me as a dev, it'd be great to have a kit new --ui-only
(or --add-ui
or something similar), to just copy over the template files, if i have devved out a process that i want to begin writing an interface for. might also consider writing the rust-facing stuff (methods normally bundled with the chat backend) in a lib_ui.rs
(or similar) file next to lib.rs
Describe the solution you'd like
A flag for new
to copy just the UI template.
Describe alternatives you've considered
new
ing up a template and copying over the relevant code by hand. Yawn!
I want to think about what behavior would be unsurprising here. One possible behavior I can imagine based on what you say here is kit n foo --ui-only
does:
foo/ exists? |
foo/ui/ exists? |
Behavior |
---|---|---|
yes | yes | error out w/ message |
yes | no | mkdir foo/ui/ |
no | no | mkdir -p foo/ui/ |
The strange thing here is that normally kit n foo
when foo/
already exists causes an error out w/ message.
Also, what if I run kit n ui --ui-only
. Does that mean I want to add a dir ui/ui/
or a dir ui/
?
@0x70b1a5 Could you clarify what you mean wrt the lib_ui.rs
? Both in general and wrt this issue?