Skip to content
Source
Sign inSign up
TanStack/cli

fix(create): preserve native build approvals across pnpm versions #485

Mergeddario-piotrowicz(GitHub profile, opens in a new tab)merged 3 commits intomain fromrefs/pull/485/headmerged by tannerlinsley

Showing 8 changed files with 50 additions and 5 deletions (loading 4).

x
0 of 8 viewed, 8 left
7 additions and 0 deletions.changeset/pnpm-native-build-approvals.mdAdded
View file
@@ -0,0 +1,7 @@
+---
+'@tanstack/create': patch
+---
+​
+Write pnpm native build approvals to pnpm-workspace.yaml for pnpm 11 while retaining package.json approvals for pnpm 9 and 10. Preserve existing workspace configuration when adding integrations.
+​
+Keep ordinary pnpm 9 dependency additions working when creating a new standalone workspace, without changing existing monorepo root checks or explicit project settings.
21 additions and 2 deletionspackages/create/src/add-to-app.tsModified
View file
@@ -16,6 +16,11 @@
recursivelyGatherFilesFromEnvironment,
} from './file-helpers.js'
import { mergePackageJSON } from './package-json.js'
+import {
+ mergePnpmWorkspace,
+ pnpmBuildDependencies,
+ standalonePnpmNpmrc,
+} from './pnpm-workspace.js'
import { runSpecialSteps } from './special-steps/index.js'
import { loadStarter } from './custom-add-ons/starter.js'
import { setupIntent } from './integrations/intent.js'
@@ -141,7 +146,7 @@
​
async function runCreateApp(options: Required<Options>) {
const { environment, output } = createMemoryEnvironment(options.targetDir)
- await createApp(environment, options)
+ await createApp(environment, options, { existingProject: true })
return output