Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Example playground: Start compat config never reaches Vite (`pnpm run dev -- --config`)

已关闭 适合新手
#1,353 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

已经有一个关联 PR 被合并了。

  • #1359 来自 @Sheraff —— 已合并

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
78/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
typescript, vite
领域
tooling

调研方向

从 src/utils/example-webcontainer-start.ts 中的 getWebContainerStartCommand 开始,并将其 pnpm 命令与 issue 中描述的可正常工作的终端命令进行比较。阅读 tests/example-webcontainer-start.test.ts,该文件目前断言的是 -- 形式。统一更新命令及其测试;完成标准是 playground 传入 Vite 配置,并且 Posts 流程在没有报告的服务器错误的情况下正常工作。

由索引模型根据 Issue 内容生成。

描述

Found while testing TanStack Router PR #8504 in the playground. The rest of this was written by Claude (an AI agent), which investigated and reproduced it.


🤖 The Start async-context compatibility config is never applied in the example playground, so server functions fail there even with published packages.

Repro: open start-basic → Playground, wait for "Ready", click Posts. The server responds 500 with No Start context found in AsyncLocalStorage and the page shows posts is not iterable.

Cause: getWebContainerStartCommand returns pnpm run dev -- --config .tanstack/vite.config.mjs. The pnpm in the WebContainer forwards the -- to the script, which runs vite dev "--" "--config" ".tanstack/vite.config.mjs", and Vite ignores everything after --. So the async-context transform, noExternal and the self-runner config are never loaded.

Running the same thing without -- in the playground terminal (NAPI_RS_NATIVE_LIBRARY_PATH=@rolldown/binding-wasm32-wasi NITRO_DEV_RUNNER=self npx vite dev --config .tanstack/vite.config.mjs --port 3001) loads the config (Vite logs "Re-optimizing dependencies because vite config has changed"), and Home → Posts → a post works.

Possible fix: drop the -- for pnpm (pnpm forwards arguments after the script name; npm still needs --), or spawn vite directly. tests/example-webcontainer-start.test.ts currently asserts the -- form.

主要语言
TypeScript
星标
1.1k
派生
405
平均合并
5 小时 51 分钟
30 天内合并 PR
58

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

TanStack/tanstack.com 的其他 Issue

查看 TanStack/tanstack.com 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。