移动系统liao
2025-05-01 a247547df86f0fad8f03aebb91de68d3f2bc7918
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
47
48
49
50
51
/*
 * @FilePath: vite.config.ts
 * @Author: 小飞侠
 * @Date: 2025-03-17 09:36:48
 * @LastEditors: Please set LastEditors
 * @LastEditTime: 2025-03-17 17:37:57
 * Copyright: 2025  MinTinge CO.,LTD. All Rights Reserved.
 * @Descripttion: 写入你的描述
 */
import { fileURLToPath, URL } from 'node:url'
 
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import vueJsx from '@vitejs/plugin-vue-jsx'
import vueDevTools from 'vite-plugin-vue-devtools'
 
// https://vite.dev/config/
export default defineConfig({
  plugins: [
    vue(),
    vueJsx(),
    vueDevTools(),
  ],
  // // 服务端渲染
  // server: {
 
  //   // 本地跨域代理 https://cn.vitejs.dev/config/server-options.html#server-proxy
  //   proxy: {
  //     "/api": {
 
  //       // 这里填写后端地址
  //       target: "http://localhost:5000",
  //       changeOrigin: true,
  //       rewrite: path => path.replace(/^\/api/, "/api")
  //     },
  //     "/ws": {
  //       target: "https://apis.map.qq.com/",
  //       changeOrigin: true,
  //       rewrite: path => path.replace(/^\/ws/, "/ws")
  //     }
  //   },
 
 
  // },
 
  resolve: {
    alias: {
      '@': fileURLToPath(new URL('./src', import.meta.url))
    },
  },
})