Skip to content
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

feat(create-vite): add help usage #16390

Merged
merged 8 commits into from
Jun 17, 2024

Conversation

edvardsanta
Copy link
Contributor

@edvardsanta edvardsanta commented Apr 9, 2024

Description

closes #16374
image

- help argument will be used as "--help" and by default it is false
- i want to find a way to decouple the text from the code
Copy link

stackblitz bot commented Apr 9, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@edvardsanta edvardsanta changed the title Feat/add help create vite feat: add create vite help usage Apr 9, 2024
@edvardsanta edvardsanta changed the title feat: add create vite help usage feat(create-vite): add help usage Apr 10, 2024
- Using alias to define template and help
@edvardsanta edvardsanta marked this pull request as ready for review April 11, 2024 04:14
Copy link
Member

@bluwy bluwy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some formatting nits, otherwise a nice addition to me!

packages/create-vite/src/index.ts Outdated Show resolved Hide resolved
packages/create-vite/src/index.ts Outdated Show resolved Hide resolved
@bluwy bluwy added p2-nice-to-have Not breaking anything but nice to have (priority) feat: create-vite create-vite package labels May 18, 2024
- To improve maintainability, the help message has been moved to a separate file.
- Implemented the suggestions provided in the pull request.
@edvardsanta edvardsanta requested a review from bluwy June 6, 2024 14:38
@bluwy
Copy link
Member

bluwy commented Jun 13, 2024

Pushed a commit with some styling changes after discussing with other maintainers, here's how it looks now:
image

The hardcoding isn't the most ideal, but I think it simplifies the code a lot and the templates aren't something we update often.

@edvardsanta
Copy link
Contributor Author

edvardsanta commented Jun 13, 2024

Pushed a commit with some styling changes after discussing with other maintainers, here's how it looks now: image

The hardcoding isn't the most ideal, but I think it simplifies the code a lot and the templates aren't something we update often.

Wouldn't it be interesting to use the color properties in the Framework type? It would make the process more dynamic instead of manually creating them for each new framework.

Edit: It can be a technical debt. I will try to make some modifications in the future

@bluwy
Copy link
Member

bluwy commented Jun 13, 2024

Yeah I did try that but to do so and others, it slows creeps in as a lot of code compared to hardcoding. So I leaned directly to the simplest way for now.

@edvardsanta
Copy link
Contributor Author

Yeah I did try that but to do so and others, it slows creeps in as a lot of code compared to hardcoding. So I leaned directly to the simplest way for now.

I tried to make it more dynamic, but I forgot that we have four types of React, and the variants ended up looking strange.
image

@bluwy
Copy link
Member

bluwy commented Jun 13, 2024

Yeah that was also the part where I threw my hand and went for the simpler path instead 😄 It's hard to sort that one with a specific hardcoding too.

@bluwy bluwy merged commit 1d9bfc0 into vitejs:main Jun 17, 2024
11 checks passed
@edvardsanta edvardsanta deleted the feat/add-help-create-vite branch June 21, 2024 13:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat: create-vite create-vite package p2-nice-to-have Not breaking anything but nice to have (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

create-vite: add CLI argument help
2 participants