Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chlbri/vitest-cov-exclude
https://github.com/chlbri/vitest-cov-exclude
Last synced: 26 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/chlbri/vitest-cov-exclude
- Owner: chlbri
- License: mit
- Created: 2024-05-20T15:08:04.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-05-20T15:08:07.000Z (8 months ago)
- Last Synced: 2024-05-21T06:19:24.853Z (8 months ago)
- Language: TypeScript
- Size: 37.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## Add tsconfig alias to vitess alias
Check the vitest.config.ts file to see how to use.
Just pass the tsconfig.json file as parameter (the "_json_", not the
"**filename**")```typescript
import { defineConfig } from 'vitest/config';
import { aliasTs } from '@bemedev';
/**
* Make sure you add "resolveJsonModule": true
* inside your tsconfig.json at compilerOPtions
* or write the json file directly
*/
import tsconfig from './tsconfig.json';export default defineConfig({
plugins: [aliasTs(tsconfig)],
test: {
environment: 'node',
globals: true,coverage: {
enabled: true,
extension: 'ts',
reportsDirectory: '.coverage',
all: true,
exclude: ['**/types.ts', '**/index.ts'],
provider: 'v8',
},
},
});
```