27 lines
584 B
TypeScript
27 lines
584 B
TypeScript
import { defineConfig } from 'vite'
|
|
import vue from '@vitejs/plugin-vue'
|
|
import path from 'path'
|
|
|
|
// https://vite.dev/config/
|
|
export default defineConfig({
|
|
plugins: [vue()],
|
|
resolve: {
|
|
alias: {
|
|
'@': path.resolve(__dirname, './src'),
|
|
'@KTXC': path.resolve(__dirname, '../../core/src')
|
|
},
|
|
},
|
|
build: {
|
|
outDir: 'static',
|
|
sourcemap: true,
|
|
lib: {
|
|
entry: path.resolve(__dirname, 'src/main.ts'),
|
|
formats: ['es'],
|
|
fileName: () => 'module.mjs',
|
|
},
|
|
rollupOptions: {
|
|
external: ['vue', 'vue-router', 'pinia'],
|
|
},
|
|
},
|
|
})
|