TanStack / TanStack/cli

create-tsrouter-app scaffold fails out of the box with pnpm on Linux

Open
#395 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
1.3k
Forks
185
Avg merge
18h 45m
Merged PRs (30d)
2

Description

Which project does this relate to?

Router

Describe the bug

Running pnpm install and pnpm dev on a freshly scaffolded TanStack Start project fails immediately without any modifications.

Your Example Website or App

none

Steps to Reproduce the Bug or Issue

Steps to reproduce

  1. Scaffold a new project using the TanStack Start template
  2. pnpm install
  3. pnpm dev
Expected behavior

Expected behavior

A freshly scaffolded project should work after pnpm install with no manual fixes required.

Screenshots or Videos

No response

Platform

Environment

OS Linux x64 (Ubuntu)
Node v22.22.0
pnpm v10.30.1
@tanstack/react-start 1.162.4
Additional context

First error: esbuild postinstall fails with:

Error: Expected "0.27.3" but got ""

The scaffold pins esbuild@0.27.3 directly in dependencies, which has a broken postinstall script under Node 22.

Second error (after removing esbuild from dependencies and letting it be a transitive dep): lightningcss native binary missing:

Error: Cannot find module '../lightningcss.linux-x64-gnu.node'

pnpm's strict symlinking means the lightningcss-linux-x64-gnu optional dependency binary never gets linked into lightningcss's node/ directory.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the TanStack Start scaffold template and its package.json dependency definitions, then reproduce the failure with pnpm install and pnpm dev on Linux. Investigate the reported esbuild postinstall and lightningcss native-binary errors; done means a freshly scaffolded project installs and starts without manual dependency changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, react, typescript
Domain
build-system, cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.