- Nx 22.7 monorepo (pnpm 11.1, TypeScript 5.9, Node 24) - apps/api: NestJS 11 (CJS conforme CODING-RULES.md PGD-DB-004) - apps/web: React 19 + Vite 8 (ESM) - libs/shared/api-interface: Zod contract base - Docker Compose dev: Postgres 18, Valkey 8, MinIO, Mailpit - WDS artifacts: - design-artifacts/A-Product-Brief/ (5 docs canônicos + 16 dialogs) - design-artifacts/B-Trigger-Map/ (hub + 4 personas + feature impact) - Stack canon: STACK.md v2.2 + CODING-RULES.md v2.0 + brand.md - AGENTS.md + README.md como entrada para devs/agentes Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
44 lines
1.1 KiB
TypeScript
44 lines
1.1 KiB
TypeScript
/// <reference types='vitest' />
|
|
import { defineConfig } from 'vite';
|
|
import react from '@vitejs/plugin-react';
|
|
import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin';
|
|
import { nxCopyAssetsPlugin } from '@nx/vite/plugins/nx-copy-assets.plugin';
|
|
|
|
export default defineConfig(() => ({
|
|
root: import.meta.dirname,
|
|
cacheDir: '../../node_modules/.vite/apps/web',
|
|
server: {
|
|
port: 4200,
|
|
host: 'localhost',
|
|
},
|
|
preview: {
|
|
port: 4200,
|
|
host: 'localhost',
|
|
},
|
|
plugins: [react(), nxViteTsPaths(), nxCopyAssetsPlugin(['*.md'])],
|
|
// Uncomment this if you are using workers.
|
|
// worker: {
|
|
// plugins: () => [ nxViteTsPaths() ],
|
|
// },
|
|
build: {
|
|
outDir: '../../dist/apps/web',
|
|
emptyOutDir: true,
|
|
reportCompressedSize: true,
|
|
commonjsOptions: {
|
|
transformMixedEsModules: true,
|
|
},
|
|
},
|
|
test: {
|
|
name: 'web',
|
|
watch: false,
|
|
globals: true,
|
|
environment: 'jsdom',
|
|
include: ['{src,tests}/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
|
|
reporters: ['default'],
|
|
coverage: {
|
|
reportsDirectory: '../../coverage/apps/web',
|
|
provider: 'v8' as const,
|
|
},
|
|
},
|
|
}));
|