From 27f42527c4f060d4b0354ff79690262fe287e641 Mon Sep 17 00:00:00 2001
From: haoxuan <haoxuan>
Date: 星期三, 24 一月 2024 11:57:15 +0800
Subject: [PATCH] 右側图标和左侧的切换设备对齐样式调整
---
vite.config.ts | 73 ++++++++++++++++++++++++++++++++++--
1 files changed, 69 insertions(+), 4 deletions(-)
diff --git a/vite.config.ts b/vite.config.ts
index 692b8dc..a5da4ec 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -6,7 +6,10 @@
import IconsResolver from 'unplugin-icons/resolver'
import Icons from 'unplugin-icons/vite'
import { ElementPlusResolver } from 'unplugin-vue-components/resolvers'
-
+// 鎵撳寘 鍏煎浣庣増鏈祻瑙堝櫒
+// import legacy from '@vitejs/plugin-legacy'
+// 寮�鍙戠幆澧冨吋瀹�
+import esbuild from 'rollup-plugin-esbuild'
const pathSrc = path.resolve(__dirname, 'src')
// https://vitejs.dev/config/
@@ -14,7 +17,8 @@
server: {
proxy: {
'/v1/': {
- target: 'http://192.168.20.4:8003',
+ // http://192.168.20.119:8003 http://192.168.20.25:7010
+ target: 'http://192.168.20.119:8003',
ws: true,
changeOrigin: true
}
@@ -23,7 +27,27 @@
resolve: {
alias: {
'@': pathSrc
+ },
+ },
+
+ build: {
+ minify:'terser',
+ // ,'edge90','firefox90','safari15'
+ target:['chrome52'],
+ cssTarget:["chrome52"],
+ },
+ css:{
+ postcss:{
+ plugins:[
+ require('postcss-pxtorem')({
+ // ipad:1280-800
+ rootValue:160.0, //鎹㈢畻鐨勫熀鏁帮紝 灞忓箷瀹藉害/10
+ propList:['*'],//闇�瑕佽浆鍖栫殑灞炴�э紝*琛ㄧず鎵�鏈夊睘鎬ч兘闇�瑕佽浆鍖�
+ // unitPrecision:5
+ })
+ ]
}
+
},
plugins: [
vue(),
@@ -42,6 +66,40 @@
dts: path.resolve(pathSrc, 'auto-imports.d.ts')
}),
+ // 寮�鍙戠幆澧冨吋瀹�
+ esbuild({
+ target:"chrome64",
+ loaders:{
+ ".vue":'js',
+ ".ts":'js'
+ }
+ }),
+ // 鍏煎浣庣増鏈祻瑙堝櫒
+ // legacy({
+ // // ie >= 11
+ // targets: ['defaults', 'not IE 11', 'chrome < 60','firefox < 59'], //闇�瑕佸吋瀹圭殑鐩爣鍒楄〃锛屽彲浠ヨ缃涓�
+ // additionalLegacyPolyfills: ['regenerator-runtime/runtime'],
+ // // renderLegacyChunks: true,
+ // modernPolyfills:true,
+ // polyfills: [
+ // 'es.symbol',
+ // 'es.array.filter',
+ // 'es.promise',
+ // 'es.promise.finally',
+ // 'es/map',
+ // 'es/set',
+ // 'es.array.for-each',
+ // 'es.object.define-properties',
+ // 'es.object.define-property',
+ // 'es.object.get-own-property-descriptor',
+ // 'es.object.get-own-property-descriptors',
+ // 'es.object.keys',
+ // 'es.object.to-string',
+ // 'web.dom-collections.for-each',
+ // 'esnext.global-this',
+ // 'esnext.string.match-all'
+ // ]
+ // }),
Components({
resolvers: [
// 鑷姩娉ㄥ唽鍥炬爣缁勪欢
@@ -55,6 +113,13 @@
}),
Icons({
autoInstall: true
- })
- ]
+ }),
+ ],
+ // configureWebpack:config=>{
+ // config.entry.app=['babel-polyfill','./src/main.js']
+ // },
+ // transpileDependencies:['*']
+ // chainWebpack: (config) => {
+ // config.entry('main').add('babel-polyfill')
+ // },
})
--
Gitblit v1.8.0