tanstack-cli --router-only project tanstack-query add on scaffolds a tanstack-start router.tsx

未關閉
#522 2 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

@tannerlinsley 已經在處理了。

開始於 2026年11月19日。

  • #584 來自 @tannerlinsley —— 未關閉

評估

難度
3/5
預估耗時
1-2 天
新手友好度
45/100
Issue 類型
缺陷
描述清晰度
基本清楚
活躍度
活躍
技術堆疊
react, typescript
領域
cli

研究方向

Start by reproducing the report: create a React app with --router-only, then run add tanstack-query and check the generated files. The payload does not name the add-on source files, so find where the tanstack-query add-on writes router.tsx and where it inserts the provider. Done means the add-on no longer creates an unused router.tsx and the app root is wrapped in a query provider. The request to support --router-only on create is a separate question; confirm with maintainers before changing it.

由索引模型根據 Issue 內容生成。

描述

Which project does this relate to?

Create Tanstack App

Describe the bug

Tanstack query add-on command adds a router.tsx file which is unused and doesn't wrap the app in a query provider like the previous cli tooling used to do.

Your Example Website or App

http://#

Steps to Reproduce the Bug or Issue

If you create a new app: I used this command:

pnpm dlx @tanstack/cli@latest create frontend \ 
  --router-only \
  --framework react \
  --package-manager pnpm \
  --toolchain eslint \
  --no-examples \
  --tailwind \
  --no-git \
  -y

I then added some add-ons as you can no longer add add-ons through the create interactive cli for router only

pnpm dlx @tanstack/cli@latest add \             
  shadcn \       
  t3env \            
  tanstack-query \        
  paraglide \         
  compiler 
Expected behavior

For the cli command to be able to accept router-only flag or for the router-only cli to enable add ons as part of start up

Screenshots or Videos

No response

Platform

MacOS

Additional context

No response

主要語言
TypeScript
星號
1.3k
分支
188
平均合併
5 小時 30 分鐘
30 天內合併 PR
42

環境準備

  • 沒有 Dockerfile 或 Docker Compose 檔案
  • 沒有 Pull Request 範本
  • 閱讀貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

TanStack/cli 的其他 Issue

查看 TanStack/cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。