1 Star 1 Fork 27

KAI/ruoyi-plus-miniapp

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
vite.config.ts 859 Bytes
一键复制 编辑 原始数据 按行查看 历史
玲娜贝er 提交于 2024-07-10 17:15 . 提交
import { defineConfig, loadEnv } from 'vite';
import uni from '@dcloudio/vite-plugin-uni';
import Unocss from 'unocss/vite';
import Components from '@uni-helper/vite-plugin-uni-components';
import { WotResolver } from '@uni-helper/vite-plugin-uni-components/resolvers';
import { resolve } from 'path';
// https://vitejs.dev/config/
export default ({ mode }: { mode: string }) => {
const env = loadEnv(mode, process.cwd());
const publicPath = env.VITE_PUBLIC_PATH ?? '/';
return defineConfig({
plugins: [
Components({
resolvers: [WotResolver()],
dts: './types/components.d.ts',
}),
uni(),
Unocss(),
],
base: publicPath,
server: {
port: 3002,
},
resolve: {
alias: {
'@': resolve(__dirname, './src'),
'#': resolve(__dirname, './types'),
},
},
});
};
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/kiki1373639299/ruoyi-plus-miniapp.git
git@gitee.com:kiki1373639299/ruoyi-plus-miniapp.git
kiki1373639299
ruoyi-plus-miniapp
ruoyi-plus-miniapp
main

搜索帮助

0d507c66 1850385 C8b1a773 1850385