Commit beb49b3
committed
fix(create): context-aware hint on the built-in escape-hatch entry
The escape-hatch entry's hint read
"Use defaults (monorepo / application / library / generator)" in all
contexts. Two problems inside an existing monorepo:
- `vite:monorepo` gets refused at scaffold time ("Cannot create a
monorepo inside an existing monorepo", bin.ts:468-472).
- `vite:generator` is never part of `getInitialTemplateOptions` —
it's only reachable via an explicit `vp create vite:generator`.
So the hint was over-promising. Now it mirrors what
`getInitialTemplateOptions(isMonorepo)` actually offers:
- outside a monorepo: "Use defaults (monorepo / application / library)"
- inside a monorepo: "Use defaults (application / library)"
RFC examples updated to match, plus a one-sentence note explaining
that the hint is context-aware.1 parent 71dd73f commit beb49b3
2 files changed
Lines changed: 15 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
47 | 53 | | |
48 | 54 | | |
49 | 55 | | |
50 | | - | |
| 56 | + | |
51 | 57 | | |
52 | 58 | | |
53 | 59 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
395 | 395 | | |
396 | 396 | | |
397 | 397 | | |
398 | | - | |
| 398 | + | |
399 | 399 | | |
400 | 400 | | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
401 | 407 | | |
402 | 408 | | |
403 | 409 | | |
| |||
449 | 455 | | |
450 | 456 | | |
451 | 457 | | |
452 | | - | |
| 458 | + | |
453 | 459 | | |
454 | 460 | | |
455 | 461 | | |
| |||
0 commit comments