CLI Add Routes in project creation process #203
Shane-Donlon
started this conversation in
Proposals For Qwik
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
What is it about?
Qwik CLI - Auto Add Routes
What's the motivation for this proposal?
I thought to put this out there as a discussion see what people / the community thinks
If this is a duplication sorry - couldn't find anything else on the topic.
Problems you are trying to solve:
Scenario:
I know at the start of my project I will want 3 pages
Home page
About Us page
Contact Us page
This can be done via the CLI when I enter
npm create qwik@latestGoals you are trying to achieve:
Any other context or information you want to share:
Add an option to the CLI that allows the Dev to add pages via the CLI
npm create qwik@latestSomewhere around this question:
Proposed Solution / Feature
What do you propose?
Example input
about, Contact US,
1 create array from input
For loop
2 convert string to lower case
3 trim spaces
4 if spaces in string replace with a hyphen -
5 create folder
6 add index.tsx to folder
possible downsides / additional things to consider
Doesn't take developer choice of JSX or TSX into consideration (although current CLI has same)
Links / References
No response
Beta Was this translation helpful? Give feedback.
All reactions