Haoqun Jiang [Fri, 7 Mar 2025 05:56:50 +0000 (13:56 +0800)]
feat!: use a giant multiselect instead of individual toggles for features (#695)
As we are adding more features, the number of toggles is getting out of hand. A multiselect could save a few keystrokes for most users.
I also take this opportunity to change the prompts library to `@clack/prompts`.
(For context: `create-astro`, `sv`, `create-preact`, `create-solid`, `create-qwik` all use `@clack/prompts`, `create-vite` recently switched to `@clack/prompts` too, while `create-next-app` uses `prompts`)
The color library is changed to `picocolors`. IMO `kleur` is still the smaller library because of treeshaking. But `@clack/prompts` already comes with `picocolors` as a dependency, so by not adding `kleur`, we save a few bytes.
---
This is a proof-of-concept PR. I haven't put much consideration into the code style yet. Nor have I updated the i18n messages. I will do that if this change is accepted.
See the result in a screen recording:
[](https://asciinema.org/a/Aq334bHe0tJBpuxLNQyVAyzXb)
---
TODOs:
- [x] Clean up the code (wrap the `isCancel` condition; update the `needsEslint` type, etc.)
- [ ] I think we should remove the `packageName` related logic but it can be postponed into another PR
- [ ] Get the message translations reviewed
* chore: small formatting improvements to the intro/outro message [skip ci]
Still much work to do. But it's acceptable for now.
* chore: unselect -> deselect
* refactor: update English prompts
* docs: update all the locales with the new prompts
* refactor: remove some duplicated or redundant code
* refactor: further cleanup of codebase
* build: remove alias for `prompts` package
* docs: Update fr-FR.json [skip ci]
* i18n: add translations for the "should not be empty" message
Haoqun Jiang [Sun, 16 Feb 2025 16:28:04 +0000 (00:28 +0800)]
fix: explictly exclude node_modules/.bin from npm files
I don't know why .gitignore exclusion doesn't work for these files,
but both pnpm & npm packed them, as a result they are present in the
tarball: https://unpkg.com/browse/create-vue@3.14.1/template/base/node_modules/.bin/
Explicitly excluding them from the `files` field can reduce the unpacked
size by quite a few KBs.
Haoqun Jiang [Thu, 6 Feb 2025 15:57:40 +0000 (23:57 +0800)]
fix: add `cypress install` to `prepare` script to fix pnpm 10 compatibility
This approach works with both pnpm 10 and other package managers:
- If Cypress's `postinstall` script has been run, it'll do nothing other
than print a message.
- If `postinstall` hasn't been run, it'll download the Cypress binary.
As for why using `prepare` instead of `postinstall`, please refer to the
discussion thread where `husky` decided to use `prepare`:
- <https://github.com/typicode/husky/issues/884>
Haoqun Jiang [Tue, 24 Dec 2024 15:37:05 +0000 (23:37 +0800)]
chore: move jsconfig.json location for cypress e2e
This is a follow up of https://github.com/vuejs/create-vue/commit/5027f2b5c49fc4b4f8c467b72025f52c9603cbb2
but of less importance, as I don't expect many tools to rely on this file's location.
Haoqun Jiang [Mon, 23 Dec 2024 10:10:54 +0000 (18:10 +0800)]
chore: small updates to the welcome page (#647)
- Replaced Cypress Component Testing with Vitest
- Added reference to Playwright
- Removed Vue.js News link as it's been inactive for more than 3 years
- Updated Vue.js Social Media accounts
- Added a link to open README.md in the editor
- Fixed an ambiguity caused by Oxford comma
Hornwitser [Tue, 19 Nov 2024 13:59:27 +0000 (14:59 +0100)]
fix: add run to build command when using bun (#615)
If the package manager is bun and the command is build generate 'bun run
build' as the command to invoke the build script instead of the built-in
'bun build' command.
Haoqun Jiang [Sat, 9 Nov 2024 07:26:10 +0000 (15:26 +0800)]
refactor: remove `baseUrl` from all TSConfig files
Per the [official documentation](https://www.typescriptlang.org/tsconfig/#baseUrl):
> This feature was designed for use in conjunction with AMD module
loaders in the browser, and is not recommended in any other context.
As of TypeScript 4.1, baseUrl is no longer required to be set when using paths.