diff --git a/src/steps/2.addModules/moduleConfigs/auth.ts b/src/steps/2.addModules/moduleConfigs/auth.ts index c19eebf..1f4b87e 100644 --- a/src/steps/2.addModules/moduleConfigs/auth.ts +++ b/src/steps/2.addModules/moduleConfigs/auth.ts @@ -84,13 +84,14 @@ const auth: ModuleConfig = { dependencies: [ { name: "@sidebase/nuxt-auth", - version: "^0.5.0", + version: "^0.6.4", isDev: true }, { name: "next-auth", version: "4.21.1", isDev: false, + isPeer: true, } ], nuxtConfig: { diff --git a/src/steps/2.addModules/moduleConfigs/naiveui.ts b/src/steps/2.addModules/moduleConfigs/naiveui.ts index fc771d4..1b174bb 100644 --- a/src/steps/2.addModules/moduleConfigs/naiveui.ts +++ b/src/steps/2.addModules/moduleConfigs/naiveui.ts @@ -31,7 +31,7 @@ const naiveui: ModuleConfig = { description: "A Vue 3 Component Library. Complete, Customizable, Uses TypeScript, Fast. See more: https://www.naiveui.com/", dependencies: [{ name: "@bg-dev/nuxt-naiveui", - version: "^1.5.1", + version: "^1.8.1", isDev: true }], nuxtConfig: { diff --git a/src/steps/2.addModules/moduleConfigs/prisma.ts b/src/steps/2.addModules/moduleConfigs/prisma.ts index 98cd5ac..98b51cd 100644 --- a/src/steps/2.addModules/moduleConfigs/prisma.ts +++ b/src/steps/2.addModules/moduleConfigs/prisma.ts @@ -106,12 +106,12 @@ const prisma: ModuleConfig = { dependencies: [ { name: "prisma", - version: "^5.4.1", + version: "^5.7.1", isDev: true }, { name: "@prisma/client", - version: "^5.4.1", + version: "^5.7.1", isDev: false } ], diff --git a/src/steps/2.addModules/moduleConfigs/tailwind.ts b/src/steps/2.addModules/moduleConfigs/tailwind.ts index 887c0ca..231088e 100644 --- a/src/steps/2.addModules/moduleConfigs/tailwind.ts +++ b/src/steps/2.addModules/moduleConfigs/tailwind.ts @@ -19,7 +19,7 @@ const tailwind: ModuleConfig = { description: "A utility-first CSS framework packed with classes that can be composed to build any design, directly in your markup. See more: https://tailwindcss.com/", dependencies: [{ name: "@nuxtjs/tailwindcss", - version: "^6.8.0", + version: "^6.10.4", isDev: true }], nuxtConfig: { diff --git a/src/steps/2.addModules/moduleConfigs/trpc.ts b/src/steps/2.addModules/moduleConfigs/trpc.ts index 7e6a061..7127865 100644 --- a/src/steps/2.addModules/moduleConfigs/trpc.ts +++ b/src/steps/2.addModules/moduleConfigs/trpc.ts @@ -130,15 +130,15 @@ const trpc: ModuleConfig = { description: "Build end-to-end typesafe APIs in Nuxt applications. See more: https://trpc.io/", dependencies: [{ name: "@trpc/server", - version: "^10.40.0", + version: "^10.45.0", isDev: false }, { name: "@trpc/client", - version: "^10.40.0", + version: "^10.45.0", isDev: false }, { name: "trpc-nuxt", - version: "^0.10.12", + version: "^0.10.15", isDev: false }, { name: "zod", @@ -146,7 +146,7 @@ const trpc: ModuleConfig = { isDev: false }, { name: "superjson", - version: "^1.12.2", + version: "^2.2.1", isDev: false }], nuxtConfig: { diff --git a/src/utils/addPackageDependency.ts b/src/utils/addPackageDependency.ts index d6efd14..22aa0ec 100644 --- a/src/utils/addPackageDependency.ts +++ b/src/utils/addPackageDependency.ts @@ -6,6 +6,7 @@ export interface Dependency { name: string version: string isDev: boolean + isPeer?: boolean } export const addPackageDependencies = async (opts: { @@ -17,11 +18,15 @@ export const addPackageDependencies = async (opts: { const pathToPackageJson = resolve(`./${projectDir}/package.json`) const packageJson = await readPackageJSON(pathToPackageJson) - for (const { name, version, isDev } of dependencies) { + for (const { name, version, isDev, isPeer } of dependencies) { if (isDev) { packageJson.devDependencies = defu(packageJson.devDependencies, { [name]: version }) + } else if (isPeer) { + packageJson.peerDependencies = defu(packageJson.peerDependencies, { + [name]: version + }) } else { packageJson.dependencies = defu(packageJson.dependencies, { [name]: version