mirror of
https://github.com/tiennm99/loto.git
synced 2026-08-31 16:26:27 +00:00
Cloudflare Pages build failed with: Error: Cannot find module '../lightningcss.linux-x64-gnu.node' Tailwind 4 → @tailwindcss/vite → lightningcss has per-platform native binaries shipped as optional npm packages. The lockfile generated on this dev box (linux-arm64) only carried the arm64 binaries, so CF on linux-x64 was missing the matching platform-specific package. Adding lightningcss-linux-x64-gnu to optionalDependencies pins it into the lockfile. On non-x64-linux machines npm skips it silently due to the platform mismatch; CF Pages on linux-x64 will install it. Pinned to 1.32.0 to match the parent dep already resolved.
31 lines
734 B
JSON
31 lines
734 B
JSON
{
|
|
"name": "loto",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "vite dev",
|
|
"dev:codeserver": "VITE_DEV_PROFILE=codeserver vite dev --host 0.0.0.0",
|
|
"build": "vite build",
|
|
"build:gh": "BUILD_PROFILE=gh vite build",
|
|
"preview": "vite preview",
|
|
"lint": "eslint ."
|
|
},
|
|
"optionalDependencies": {
|
|
"lightningcss-linux-x64-gnu": "1.32.0"
|
|
},
|
|
"devDependencies": {
|
|
"@eslint/js": "^9",
|
|
"@sveltejs/adapter-static": "^3",
|
|
"@sveltejs/kit": "^2",
|
|
"@sveltejs/vite-plugin-svelte": "^6",
|
|
"@tailwindcss/vite": "^4",
|
|
"eslint": "^9",
|
|
"eslint-plugin-svelte": "^2",
|
|
"globals": "^15",
|
|
"svelte": "^5",
|
|
"tailwindcss": "^4",
|
|
"vite": "^7"
|
|
}
|
|
}
|