MeterSphere/frontend/config/vite.config.dev.ts

32 lines
686 B
TypeScript
Raw Normal View History

2023-05-24 11:08:08 +08:00
/// <reference types="vitest" />
import { mergeConfig } from 'vite';
import eslint from 'vite-plugin-eslint';
import baseConfig from './vite.config.base';
export default mergeConfig(
{
mode: 'development',
server: {
open: true,
fs: {
strict: true,
},
2023-06-02 15:18:59 +08:00
proxy: {
2023-06-02 18:28:57 +08:00
'/front': {
target: 'http://172.16.200.18:8081/',
2023-06-02 15:18:59 +08:00
changeOrigin: true,
2023-07-04 12:05:26 +08:00
rewrite: (path: string) => path.replace(/^\/front/, ''),
2023-06-02 15:18:59 +08:00
},
},
2023-05-24 11:08:08 +08:00
},
plugins: [
eslint({
cache: false,
include: ['src/**/*.ts', 'src/**/*.tsx', 'src/**/*.vue'],
exclude: ['node_modules'],
}),
],
},
baseConfig
);