Skip to content

fix: drop /tmp + JSON-parse deps in frontend scaffolds (Windows-robust)

Akram GASSEM requested to merge fix/windows-tmp-and-jsonc into main

Two fragilities surfaced on a Windows machine whose Git-Bash /tmp is non-writable and whose tsconfig.app.json is CRLF JSONC:

  • react-vite: patched tsconfig.app.json via node JSON.parse, which choked on the JSONC comments + CRLF ("Bad control character in string literal"). Replaced with a plain-text awk insertion after the compilerOptions brace — no parsing, comments preserved, idempotent.

  • react-vite, tailwind, ladle, tanstack-router used mktemp, which fails with "Permission denied" when /tmp isn't writable. All switched to project-relative temp files (e.g. "$file.tmp"), removing the /tmp dependency entirely. (openapi-first already did this.)

Merge request reports

Loading