Files
clean-architecture-frontend…/package.json
T
donghyeon.kang bf485f449a refactor(typecheck): 음성 타입 fixture 23개를 실행기 하나로 돈다
음성 타입 fixture마다 옵션이 같은 tsconfig 하나, package script 하나,
게이트 명령 하나가 있었다(23벌). 옵션은 모두 같고 파일 하나만 달라서
fixture를 더할 때마다 세 곳을 같이 고쳤다. `tsconfig.recipes.json`도
`tsconfig.test.json`과 lib가 같고 types만 하나 적었다.
`tsconfig.web-worker.json`은 `files: []`로 0파일을 검사하고 통과했다
(2026-09-25 리뷰가 기록, FE-GATE-003이 통과로 보였다).

고른 방법(design-docs repo-structure/04-frontend-layout.md 5.3절 (가),
소유자 승인 2026-11-07):
- fixture 첫 줄에 기대(`// expect: TS2322`, `// expect: pass`)를 쓰고
  `scripts/check-type-fixtures.ts`가 fixture마다 `.tmp/type-fixtures/`에
  한 파일 tsconfig를 써서 tsc를 돈다. 판정은 run-ci-gate.ts가 명령마다
  하던 것과 같다(exit 1과 `error TS<code>:`). 결과를 fixture별로 출력한다.
  기대 줄이 없는 fixture와 fixture 0개는 실패한다.
- recipes는 `tsconfig.test.json` include로 옮긴다.
- web-worker tsconfig와 script는 지운다(결정 D4). Worker를 들일 때 더하는
  단계는 매뉴얼 03에 쓴다(뒤 커밋).
- `scripts/check-typecheck-inputs.ts`를 `check:types` 끝에 둔다. package
  script가 tsc에 넘기는 tsconfig마다 이 repo 파일이 1개 이상인지 본다.
  `files: []` tsconfig가 통과로 보이던 구멍을 막는다(R8).

버린 것: TypeScript API로 한 프로세스에서 돌리는 방법. 이 repo의
TypeScript 7.0(네이티브판)은 JS API를 싣지 않는다. 위반마다
`@ts-expect-error`를 쓰는 방법(5.3절 (나))은 오류 코드 고정을 잃는다.

위험: recipe가 이제 `vite/client` 타입이 있는 프로그램에서 검사된다.
recipe가 `import.meta.env`를 쓰면 전에는 실패했고 이제는 통과한다
(복사한 제품도 Vite라 가치가 작다, 설계 5.1절). CI 계약 기준선을 다시
받았다(명령 99 → 76).

검증(desktop): `check:types:fixtures` 23개 PASS, 각 fixture의 기대 코드가
출력에 그대로 나온다. `TelemetryPort.emit` 인자를 `string`으로 넓히는
변이(2026-09-25 리뷰 07-05)에서 `invalid-diagnostics-port.ts`가 TS2578로
FAIL, 실행기 rc=1. 되돌린 뒤 작업 트리 0줄. `check:types` rc=0
(Typecheck inputs: app 379, node 312, service-worker 22, test 915).

Refs: design-docs repo-structure/04-frontend-layout.md 5.3·9.2·9.3절, README.md 3.4절 D4
2026-11-08 17:40:12 +09:00

170 lines
16 KiB
JSON

{
"name": "clean-architecture-frontend-template",
"version": "0.2.0",
"private": true,
"type": "module",
"packageManager": "pnpm@11.17.0",
"engines": {
"node": ">=24.11.0 <25.0.0",
"pnpm": ">=11.0.0 <12.0.0"
},
"scripts": {
"dev": "node scripts/generate-product-feature-index.ts && vite",
"build": "node scripts/generate-product-feature-index.ts && node scripts/build-frontend.ts",
"build:release-candidate": "node scripts/generate-product-feature-index.ts && corepack pnpm build && corepack pnpm generate:supply-chain && corepack pnpm scan:security && corepack pnpm verify:release && node scripts/verify-supply-chain-artifacts.ts && node scripts/create-release-candidate.ts",
"preview": "vite preview",
"lint": "eslint src scripts tests recipes .storybook vite.config.ts vitest.config.ts playwright*.config.ts --max-warnings=0",
"check:architecture": "node scripts/generate-product-feature-index.ts && node scripts/check-architecture.ts",
"check:design-system": "node scripts/generate-product-feature-index.ts && node scripts/check-design-system.ts",
"check:design-system:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-design-system.ts --fixture",
"check:i18n": "node scripts/generate-product-feature-index.ts && node scripts/check-i18n.ts",
"check:i18n:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-i18n.ts --fixture",
"check:adapter-inventory": "node scripts/check-adapter-inventory.ts",
"check:backend-contract-drift": "node scripts/check-backend-contract-drift.ts",
"check:remediation-ledger": "node scripts/check-remediation-ledger.ts",
"check:release-admission": "node scripts/generate-product-feature-index.ts && node scripts/check-release-admission.ts",
"scan:dependency-advisories": "node scripts/scan-dependency-advisories.ts",
"check:diagnostics": "node scripts/generate-product-feature-index.ts && node scripts/check-diagnostics.ts",
"check:diagnostics:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-diagnostics.ts --fixture",
"check:types": "corepack pnpm check:types:app && corepack pnpm check:types:node && corepack pnpm check:types:test && corepack pnpm check:types:service-worker && node scripts/check-typecheck-inputs.ts",
"check:types:app": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.app.json",
"check:types:node": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.node.json",
"check:types:test": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.test.json",
"check:types:fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-type-fixtures.ts",
"test:runtime-schema": "node scripts/run-vitest.ts run tests/runtime-schema --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/runtime-schema.xml --passWithNoTests",
"test:unit": "node scripts/run-vitest.ts run tests/unit --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/unit.xml",
"test:contract": "node scripts/run-vitest.ts run tests/contract --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/contract.xml",
"test:system": "node scripts/check-system-test-prerequisites.ts && node scripts/run-vitest.ts run tests/system --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/system.xml",
"test:component": "node scripts/run-vitest.ts run tests/component --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/component.xml",
"test:integration": "node scripts/run-vitest.ts run tests/integration --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/integration.xml",
"test:http-scenario-catalog": "node scripts/run-vitest.ts run tests/integration/http-scenario-catalog.test.ts --reporter=default --maxWorkers=1",
"test:http-scenario-evidence": "node scripts/run-http-scenario-evidence.ts",
"test:recipes": "node scripts/run-vitest.ts run tests/recipes --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/optional-recipes.xml --passWithNoTests",
"test:e2e": "playwright test",
"test:e2e:dev": "playwright test --config playwright.dev.config.ts",
"test:browser-capabilities": "playwright test --config playwright.capabilities.config.ts",
"verify:browser-capability-evidence": "node scripts/verify-browser-capability-evidence.ts",
"storybook": "node scripts/generate-product-feature-index.ts && storybook dev -p 6006",
"build:storybook": "node scripts/generate-product-feature-index.ts && storybook build -o artifacts/storybook/static",
"test:storybook": "playwright test --config playwright.storybook.config.ts",
"test:visual": "playwright test --config playwright.visual.config.ts",
"test:visual:update": "playwright test --config playwright.visual.config.ts --update-snapshots",
"check:test-evidence": "node scripts/check-test-evidence.ts",
"check:test-evidence:browser": "node scripts/check-test-evidence.ts --skip-scenario-executions",
"check:http-scenario-evidence": "node scripts/check-test-evidence.ts --scenario-only --artifact artifacts/quality/http-scenario-evidence.json",
"check:http-scenario-evidence:fixture": "node scripts/check-test-evidence.ts --scenario-only --source-root tests/fixtures/test-evidence/scenarios/source --policy tests/fixtures/test-evidence/scenarios/policy.json --catalog tests/fixtures/test-evidence/scenarios/catalog.json --receipt tests/fixtures/test-evidence/scenarios/receipt.json --artifact artifacts/quality/http-scenario-evidence-fixture.json",
"check:test-evidence:source": "node scripts/check-test-evidence.ts --source-only --artifact artifacts/quality/test-evidence-source.json",
"check:test-evidence:fixture": "node scripts/check-test-evidence.ts --source-root tests/fixtures/test-evidence/forbidden --artifact artifacts/quality/test-evidence-fixture.json",
"test:a11y": "node scripts/generate-product-feature-index.ts && playwright test --grep @a11y && node scripts/write-a11y-report.ts",
"review:a11y-manual": "node scripts/generate-product-feature-index.ts && node scripts/verify-a11y-manual.ts",
"test:sample-removal": "node scripts/generate-product-feature-index.ts && node scripts/test-sample-removal.ts",
"test:feature-scaffold": "node scripts/generate-product-feature-index.ts && node scripts/test-feature-scaffold.ts",
"test:optional-recipe-removal": "node scripts/test-optional-recipe-removal.ts",
"test:browser-file-storage-removal": "node scripts/test-browser-file-storage-runtime-removal.ts",
"test:realtime-removal": "node scripts/test-realtime-runtime-removal.ts",
"check:v8-coverage-counter-semantics": "node scripts/check-v8-coverage-counter-semantics.ts",
"test:coverage": "corepack pnpm check:v8-coverage-counter-semantics && node scripts/run-vitest.ts run tests/runtime-schema tests/unit tests/contract tests/component tests/integration tests/features tests/platform tests/architecture tests/release tests/scripts tests/scale/browser-soak.contract.test.ts --coverage --maxWorkers=4 --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/coverage.xml && node scripts/check-risk-coverage.ts",
"check:coverage:fixture": "node scripts/check-risk-coverage.ts --summary tests/fixtures/coverage/below-threshold.json --artifact artifacts/quality/risk-coverage-fixture.json",
"test:all": "corepack pnpm test:runtime-schema && corepack pnpm test:unit && corepack pnpm test:contract && corepack pnpm test:component && corepack pnpm test:integration && node scripts/run-vitest.ts run tests/features tests/scripts tests/scale/browser-soak.contract.test.ts --reporter=default && corepack pnpm test:platform && corepack pnpm check:release-coherence && corepack pnpm test:recipes",
"verify:lockfile": "corepack pnpm install --frozen-lockfile --ignore-scripts",
"check:frozen-lockfile:fixture": "node scripts/check-frozen-lockfile-fixture.ts",
"generate:artifact-schemas": "node scripts/generate-product-feature-index.ts && node scripts/generate-artifact-schemas.ts",
"check:artifact-schemas": "node scripts/generate-product-feature-index.ts && node scripts/generate-artifact-schemas.ts --check",
"generate:supply-chain": "node scripts/generate-product-feature-index.ts && node scripts/generate-supply-chain.ts",
"verify:local-evidence": "node scripts/generate-product-feature-index.ts && node scripts/verify-release-candidate.ts && node scripts/verify-release.ts && node scripts/verify-supply-chain-artifacts.ts && node scripts/verify-archived-local-evidence.ts && node scripts/verify-release-candidate.ts",
"verify:promotion": "node scripts/generate-product-feature-index.ts && node scripts/verify-exact-promotion-bundle.ts",
"update:dependency-baseline": "node scripts/update-dependency-baseline.ts",
"check:supply-chain:fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-supply-chain-fixtures.ts",
"check:supply-chain:provider-fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-supply-chain-provider-fixtures.ts",
"verify:reproducible-build": "node scripts/generate-product-feature-index.ts && node scripts/verify-reproducible-build.ts",
"scan:security": "node scripts/security-scan.ts",
"check:security:fixtures": "node scripts/check-security-fixtures.ts",
"check:browser-security": "node scripts/check-browser-security.ts",
"check:browser-file-storage-boundaries": "node scripts/check-browser-file-storage-boundaries.ts",
"check:realtime-boundaries": "node scripts/generate-product-feature-index.ts && node scripts/check-realtime-boundaries.ts",
"check:realtime-boundaries:fixture": "node scripts/check-realtime-boundary-fixtures.ts",
"check:optional-recipes": "node scripts/generate-product-feature-index.ts && node scripts/check-optional-recipes.ts --require-dist",
"check:optional-recipes:source": "node scripts/generate-product-feature-index.ts && node scripts/check-optional-recipes.ts",
"check:optional-recipe-fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-optional-recipe-fixtures.ts",
"check:registries": "node scripts/generate-product-feature-index.ts && node scripts/check-registries.ts",
"update:registry-baseline": "node scripts/generate-product-feature-index.ts && node scripts/check-registries.ts --no-baseline --artifact artifacts/quality/registry-current-snapshot.json && node scripts/update-registry-baseline.ts",
"check:registries:compatibility-fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-registry-compatibility-fixtures.ts",
"check:registries:baseline-fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-registries.ts --approval tests/fixtures/registry/compatibility/tampered-approval.json --artifact artifacts/quality/registry-baseline-fixture.json",
"check:registries:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-registries.ts --governance tests/fixtures/registry/forbidden/governance.json --artifact artifacts/quality/registry-fixture.json",
"check:routes:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-registries.ts --governance tests/fixtures/registry/routes/governance.json --artifact artifacts/quality/route-registry-fixture.json",
"verify:compatibility": "node scripts/generate-product-feature-index.ts && node scripts/check-compatibility.ts",
"verify:release": "node scripts/generate-product-feature-index.ts && node scripts/verify-release.ts",
"verify:hosting-headers": "node scripts/generate-product-feature-index.ts && node scripts/verify-hosting-headers.ts",
"check:bundle": "node scripts/generate-product-feature-index.ts && node scripts/generate-supply-chain.ts && node scripts/check-bundle.ts",
"test:performance": "node scripts/generate-product-feature-index.ts && node scripts/test-performance.ts",
"collect:web-vitals-evidence": "node scripts/generate-product-feature-index.ts && node scripts/collect-web-vitals-evidence.ts",
"drill:runbook": "node scripts/generate-product-feature-index.ts && node scripts/drill-runbook.ts",
"drill:runbooks": "corepack pnpm drill:runbook -- FE-RB-001 && corepack pnpm drill:runbook -- FE-RB-002 && corepack pnpm drill:runbook -- FE-RB-003 && corepack pnpm drill:runbook -- FE-RB-004 && corepack pnpm drill:runbook -- FE-RB-005",
"ci:gate": "node scripts/generate-product-feature-index.ts && node scripts/run-ci-gate.ts",
"generate:ci-workflow": "node scripts/generate-ci-workflow.ts",
"check:ci-workflow": "node scripts/generate-ci-workflow.ts --check",
"check:ci": "corepack pnpm check:artifact-schemas && node scripts/check-ci-contract.ts && corepack pnpm check:ci-workflow",
"update:ci-contract-baseline": "node scripts/update-ci-contract-baseline.ts",
"verify:documentation": "node scripts/generate-product-feature-index.ts && node scripts/verify-documentation-readiness.ts",
"check:types:service-worker": "tsc --project tsconfig.service-worker.json",
"generate:feature-index": "node scripts/generate-product-feature-index.ts",
"create:feature": "node scripts/generate-product-feature-index.ts && node scripts/create-feature.ts",
"check:feature-index": "node scripts/generate-product-feature-index.ts --check",
"check:topology": "node scripts/run-vitest.ts run tests/architecture/topology-cardinality.test.ts tests/architecture/context-lazy-loading.test.ts tests/platform/cardinality tests/platform/routing --reporter=default",
"check:traffic": "node scripts/run-vitest.ts run tests/platform/execution tests/platform/traffic tests/platform/resilience --reporter=default",
"check:observability": "node scripts/run-vitest.ts run tests/platform/errors tests/platform/validation tests/platform/telemetry tests/architecture/observability-boundaries.test.ts --reporter=default",
"test:platform": "node scripts/run-vitest.ts run tests/platform tests/architecture --no-file-parallelism --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/platform.xml",
"check:scale:pr": "node scripts/scale/run-scale-profile.ts pr",
"check:scale:main": "node scripts/scale/run-scale-profile.ts main",
"check:scale:nightly": "node scripts/scale/run-scale-profile.ts nightly",
"check:scale:release": "node scripts/scale/run-scale-profile.ts release",
"check:scale:baseline": "node scripts/scale/check-scale-baseline.ts",
"update:scale-baseline": "node scripts/scale/check-scale-baseline.ts --update",
"verify:extreme-scale": "node scripts/verify-extreme-scale.ts",
"check:request-fanout": "node scripts/check-request-fanout.ts && node scripts/check-request-fanout.ts --fixture",
"check:app-build-input": "node scripts/check-app-build-input.ts",
"check:app-build-input:bundle": "node scripts/check-app-build-input.ts --require-bundle",
"test:extreme-scale:focused": "node scripts/run-vitest.ts run tests/scale/global-local-independence.test.ts tests/architecture/app-build-input.test.ts tests/architecture/request-fanout.test.ts tests/platform/traffic/request-fanout.test.ts tests/platform/traffic/request-deduplication.test.ts tests/scripts/generate-product-feature-index.test.ts --reporter=default",
"check:release-coherence": "node scripts/run-vitest.ts run tests/platform/release tests/release --reporter=default"
},
"dependencies": {
"@tanstack/react-query": "5.101.4",
"lucide-react": "1.25.0",
"react": "19.2.8",
"react-dom": "19.2.8",
"react-router-dom": "7.18.1",
"zod": "4.4.3"
},
"devDependencies": {
"@axe-core/playwright": "4.12.1",
"@babel/core": "8.0.1",
"@babel/eslint-parser": "8.0.1",
"@babel/plugin-syntax-jsx": "8.0.1",
"@babel/plugin-syntax-typescript": "8.0.3",
"@eslint/js": "10.0.1",
"@playwright/test": "1.62.0",
"@storybook/addon-a11y": "10.6.5",
"@storybook/react-vite": "10.6.5",
"@tailwindcss/vite": "4.3.3",
"@testing-library/jest-dom": "7.0.0",
"@testing-library/react": "16.3.2",
"@testing-library/user-event": "14.6.1",
"@types/node": "24.13.3",
"@types/react": "19.2.8",
"@types/react-dom": "19.2.3",
"@vitejs/plugin-react": "6.0.4",
"@vitest/coverage-v8": "4.1.12",
"dependency-cruiser": "18.1.0",
"eslint": "10.8.0",
"eslint-plugin-react-hooks": "7.1.1",
"globals": "17.7.0",
"jsdom": "29.1.1",
"msw": "2.15.0",
"storybook": "10.6.5",
"tailwindcss": "4.3.3",
"typescript": "7.0.2",
"vite": "8.1.6",
"vitest": "4.1.12"
}
}