* Prompt a user to select a package.
()
| 74 | * Prompt a user to select a package. |
| 75 | */ |
| 76 | async function selectPackage() { |
| 77 | const packages = getPackages() |
| 78 | packages.unshift('🌎 build all') |
| 79 | packages.push('🧨 cancel') |
| 80 | const { selection } = await prompts({ |
| 81 | type: 'select', |
| 82 | name: 'selection', |
| 83 | message: 'Which FormKit package do you want to build?', |
| 84 | choices: packages.map((name) => ({ |
| 85 | title: name, |
| 86 | value: name, |
| 87 | })), |
| 88 | }) |
| 89 | await buildPackage(selection) |
| 90 | } |
| 91 | |
| 92 | /** |
| 93 | * Build the selected package. |
no test coverage detected