diff --git a/flake.nix b/flake.nix index 0ecbc89..58e5046 100644 --- a/flake.nix +++ b/flake.nix @@ -148,7 +148,7 @@ pnpmDeps = (pkgs.fetchPnpmDeps.override { pnpm = pkgs.pnpm_10; }) { inherit (finalAttrs) pname version src; fetcherVersion = 3; - hash = "sha256-hOqiAbnjKsoQnV8lgto5HspDsLIb+48sNLkShIjCZPQ="; + hash = "sha256-AzF/rrhqbvl613hNsC18YSylBSVxtatg7fEiUEF1u2o="; }; buildPhase = '' diff --git a/web/package.json b/web/package.json index f496bbf..97d0369 100644 --- a/web/package.json +++ b/web/package.json @@ -6,7 +6,7 @@ "packageManager": "pnpm@9.15.4", "scripts": { "dev": "vite", - "build": "tsc -b && vite build", + "build": "tsc -b tsconfig.build.json && vite build", "preview": "vite preview", "typecheck": "tsc -b --noEmit", "test": "vitest run", diff --git a/web/tsconfig.build.json b/web/tsconfig.build.json new file mode 100644 index 0000000..88cd2cf --- /dev/null +++ b/web/tsconfig.build.json @@ -0,0 +1,8 @@ +{ + // The nix derivation's src is `./web`, so the shared fixtures/ directory at + // the repo root does not exist there and `*.test.ts` cannot resolve its + // imports. Tests are not part of the shipped bundle; `pnpm typecheck` still + // checks them from a full checkout. + "extends": "./tsconfig.json", + "exclude": ["src/**/*.test.ts", "src/**/*.test.tsx"] +}