Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

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

Đã đóng Phù hợp với người mới
#1,353 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Một pull request liên quan đã được merge.

  • #1359 của @Sheraff — đã merge

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
78/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
typescript, vite
Lĩnh vực
tooling

Hướng nghiên cứu

Bắt đầu tại src/utils/example-webcontainer-start.ts, ở getWebContainerStartCommand, rồi so sánh lệnh pnpm của nó với lệnh terminal hoạt động được mô tả trong issue. Đọc tests/example-webcontainer-start.test.ts, hiện đang kiểm tra dạng --. Cập nhật lệnh và bài kiểm thử tương ứng một cách nhất quán; hoàn tất khi playground truyền cấu hình Vite và luồng Posts hoạt động mà không gặp lỗi máy chủ được báo cáo.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

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.

Ngôn ngữ chính
TypeScript
Star
1.1k
Fork
405
Merge trung bình
5 giờ 27 phút
Pull request đã merge (30 ngày)
66

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của TanStack/tanstack.com

Tất cả issue của TanStack/tanstack.com

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.