Files
ISA-Frontend/libs/checkout/feature/reward-catalog/vite.config.mts
2025-10-14 16:02:18 +00:00

35 lines
1.2 KiB
TypeScript

/// <reference types='vitest' />
import { defineConfig } from 'vite';
import angular from '@analogjs/vite-plugin-angular';
import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin';
import { nxCopyAssetsPlugin } from '@nx/vite/plugins/nx-copy-assets.plugin';
export default
// @ts-expect-error - Vitest reporter tuple types have complex inference issues, but config works correctly at runtime
defineConfig(() => ({
root: __dirname,
cacheDir: '../../../../node_modules/.vite/libs/loyalty/feature/loyalty-list',
plugins: [angular(), nxViteTsPaths(), nxCopyAssetsPlugin(['*.md'])],
// Uncomment this if you are using workers.
// worker: {
// plugins: [ nxViteTsPaths() ],
// },
test: {
watch: false,
globals: true,
environment: 'jsdom',
include: ['{src,tests}/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
setupFiles: ['src/test-setup.ts'],
reporters: [
'default',
['junit', { outputFile: '../../../../testresults/junit-checkout-feature-reward-catalog.xml' }],
],
coverage: {
reportsDirectory:
'../../../../coverage/libs/checkout/feature/reward-catalog',
provider: 'v8' as const,
reporter: ['text', 'cobertura'],
},
},
}));