-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathvite.config.ts
46 lines (45 loc) · 1.27 KB
/
vite.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import { fileURLToPath, URL } from 'node:url';
import { defineConfig } from 'vitest/config'
import RubyPlugin from 'vite-plugin-ruby';
import vue from '@vitejs/plugin-vue';
export default defineConfig({
plugins: [
RubyPlugin(),
vue()
],
resolve: {
alias: {
vue: 'vue/dist/vue.esm-bundler.js',
'@': fileURLToPath(new URL('./app/frontend', import.meta.url)),
},
},
test: {
globals: true,
environment: 'jsdom',
coverage: {
provider: 'c8',
all: true,
include: ['app/frontend/**/*.{js,ts,vue}'],
exclude: [
/* default excludes */
'coverage/**',
'dist/**',
'packages/*/test{,s}/**',
'**/*.d.ts',
'cypress/**',
'test{,s}/**',
'test{,-*}.{js,cjs,mjs,ts,tsx,jsx}',
'**/*{.,-}test.{js,cjs,mjs,ts,tsx,jsx}',
'**/*{.,-}spec.{js,cjs,mjs,ts,tsx,jsx}',
'**/__tests__/**',
'**/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build}.config.*',
'**/.{eslint,mocha,prettier}rc.{js,cjs,yml}',
/* custom excludes */
'app/frontend/**/*.spec.{js,ts,vue}',
'app/frontend/**/*.mock.{js,ts,vue}',
'app/frontend/active_admin/jquery.js',
'app/frontend/entrypoints',
]
}
},
})