File tree 1 file changed +26
-24
lines changed
1 file changed +26
-24
lines changed Original file line number Diff line number Diff line change 1
- import config from './vite.config.js'
2
- /**
3
- * @type {import('vite').UserConfig }
4
- */
5
- export default Object . assign ( config , {
6
- ssr : {
7
- noExternal : / ./ ,
8
- } ,
9
- resolve : {
10
- // necessary because vue.ssrUtils is only exported on cjs modules
11
- alias : [
12
- {
13
- find : '@vue/runtime-dom' ,
14
- replacement : '@vue/runtime-dom/dist/runtime-dom.cjs.js' ,
15
- } ,
16
- {
17
- find : '@vue/runtime-core' ,
18
- replacement : '@vue/runtime-core/dist/runtime-core.cjs.js' ,
19
- } ,
20
- ] ,
21
- } ,
22
- optimizeDeps : {
23
- exclude : [ '@vitejs/test-example-external-component' ] ,
24
- } ,
1
+ import { defineConfig } from 'vite'
2
+ import createConfig from './vite.config.js'
3
+
4
+ export default defineConfig ( ( env ) => {
5
+ const config = createConfig ( env )
6
+ return Object . assign ( config , {
7
+ ssr : {
8
+ noExternal : / ./ ,
9
+ } ,
10
+ resolve : {
11
+ // necessary because vue.ssrUtils is only exported on cjs modules
12
+ alias : [
13
+ {
14
+ find : '@vue/runtime-dom' ,
15
+ replacement : '@vue/runtime-dom/dist/runtime-dom.cjs.js' ,
16
+ } ,
17
+ {
18
+ find : '@vue/runtime-core' ,
19
+ replacement : '@vue/runtime-core/dist/runtime-core.cjs.js' ,
20
+ } ,
21
+ ] ,
22
+ } ,
23
+ optimizeDeps : {
24
+ exclude : [ '@vitejs/test-example-external-component' ] ,
25
+ } ,
26
+ } )
25
27
} )
You can’t perform that action at this time.
0 commit comments