Skip to content

Commit

Permalink
fix(CLI): shadcn-vue init not installing all dependencies or devDep…
Browse files Browse the repository at this point in the history
…endencies (#469)
  • Loading branch information
sadeghbarati committed Apr 6, 2024
1 parent 75d10d5 commit 9712ba9
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions packages/cli/src/commands/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,19 +292,13 @@ export async function runInit(cwd: string, config: Config) {
config.style === 'new-york' ? ['@radix-icons/vue'] : ['lucide-vue-next'],
).filter(Boolean)

async function addNuxtDevDeps() {
if (config.framework === 'nuxt') {
await addDevDependency(PROJECT_DEPENDENCIES.nuxt, {
cwd,
silent: true,
})
}
}

await Promise.allSettled(
[
addNuxtDevDeps(),
addDependency(deps, {
config.framework === 'nuxt' && await addDevDependency(PROJECT_DEPENDENCIES.nuxt, {
cwd,
silent: true,
}),
await addDependency(deps, {
cwd,
silent: true,
}),
Expand Down

0 comments on commit 9712ba9

Please sign in to comment.