vitest.config.ts 401 B

123456789101112131415161718
  1. import { defineConfig } from 'vitest/config';
  2. import react from '@vitejs/plugin-react';
  3. import path from 'node:path';
  4. export default defineConfig({
  5. plugins: [react()],
  6. resolve: {
  7. alias: {
  8. '@': path.resolve(__dirname, 'src'),
  9. },
  10. },
  11. test: {
  12. environment: 'happy-dom',
  13. globals: true,
  14. setupFiles: ['./tests/setup.ts'],
  15. include: ['tests/**/*.test.{ts,tsx}'],
  16. },
  17. });