-
Notifications
You must be signed in to change notification settings - Fork 4
/
vite.config.ts
33 lines (29 loc) · 1003 Bytes
/
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
import { defineConfig, splitVendorChunkPlugin } from 'vite'
import vue from '@vitejs/plugin-vue'
import prismjs from 'vite-plugin-prismjs'
import { dirname, resolve } from 'node:path'
import { fileURLToPath } from 'node:url'
const root = dirname(fileURLToPath(import.meta.url))
export default defineConfig({
plugins: [
splitVendorChunkPlugin(),
vue(),
prismjs({
languages: [ 'javascript', 'typescript', 'bash', 'markup', 'haskell' ],
theme: 'okaidia',
css: true
})
],
resolve: {
alias: {
'vue': 'vue/dist/vue.esm-bundler.js',
'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js',
'@': resolve(root, 'src'),
'@pack': resolve(root, 'package.json'),
'@comp': resolve(root, 'src/components'),
'@dir': resolve(root, 'src/directives'),
'@util': resolve(root, 'src/utils'),
'@store': resolve(root, 'src/stores')
}
}
})