Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .changeset/ai-threadid-and-empty-pnpm-key.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@tanstack/create': patch
---

fix(create): make AI add-on chat sample work out of the box and drop the empty `pnpm` key

- The AI add-on's chat hook now passes the required `threadId` to `useChat`, so the generated sample runs without manual fixing.
- Removed the empty `"pnpm": {}` key from the React and Solid base templates so generated projects no longer carry an invalid, empty `pnpm` field. Add-ons that need `pnpm.onlyBuiltDependencies` still inject it.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@ const chatOptions = createChatClientOptions({

export type ChatMessages = InferChatMessages<typeof chatOptions>

export const useGuitarRecommendationChat = () => useChat(chatOptions)
export const useGuitarRecommendationChat = () =>
useChat({ ...chatOptions, threadId: 'guitar-recommendations' })
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,5 @@
"react": "^19.2.0",
"react-dom": "^19.2.0"
},
"devDependencies": {},
"pnpm": {}
"devDependencies": {}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,5 @@
"@tanstack/solid-start": "latest",
"solid-js": "^1.9.12"
},
"devDependencies": {},
"pnpm": {}
"devDependencies": {}
}
Loading