-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvite.config.ts
More file actions
34 lines (31 loc) · 882 Bytes
/
vite.config.ts
File metadata and controls
34 lines (31 loc) · 882 Bytes
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
// vite.config.js
import { resolve } from 'path'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
export default defineConfig({
build: {
lib: {
// Could also be a dictionary or array of multiple entry points
entry: resolve(__dirname, 'index.ts'),
name: 'alphaviewlibrary',
// the proper extensions will be added
fileName: 'alphaviewlibrary',
},
rollupOptions: {
// make sure to externalize deps that shouldn't be bundled
// into your library
external: ['vue', 'quasar', 'lodash'],
output: {
// Provide global variables to use in the UMD build
// for externalized deps
globals: {
vue: 'vue',
quasar: 'quasar',
lodash: 'lodash'
},
},
},
},
plugins: [ vue({
include: [/\.vue$/, /\.md$/] }), ]
})