Files
faunosteo/vitest.config.ts
T
ZenQuality 3fb77c3530 chore: scaffold fixes — React 19 JSX, vitest v3, @types/node, lint scoping
- React 19 dropped global JSX namespace; stub return types removed (TS infer)
- vitest 2 pulled vite 5 alongside project vite 6 → upgrade vitest to 3 (dedupes)
- Add @types/node to devDeps so vite/vitest configs compile
- ESLint flat config: scope strictTypeChecked to src/ + tests/, ignore config files
- tsconfig.app.json: include tests/, add vitest/globals to types
- vite.config.ts + vitest.config.ts: use import.meta.dirname instead of __dirname
- pdf/export + pdf/import: stub returns Promise.reject so require-await rule clears
- tests/unit/smoke.test.ts: keep vitest run from exiting 1 with no tests
2026-05-17 06:47:52 +02:00

24 lines
541 B
TypeScript

import react from '@vitejs/plugin-react';
import path from 'node:path';
import { defineConfig } from 'vitest/config';
export default defineConfig({
plugins: [react()],
resolve: {
alias: {
'@': path.resolve(import.meta.dirname, 'src'),
},
},
test: {
globals: true,
environment: 'jsdom',
setupFiles: ['./tests/unit/setup.ts'],
coverage: {
provider: 'v8',
reporter: ['text', 'lcov'],
include: ['src/**/*.{ts,tsx}'],
exclude: ['src/**/*.d.ts', 'src/vite-env.d.ts'],
},
},
});