vite.config.js 411 B

1234567891011121314151617
  1. import {defineConfig} from 'vite'
  2. import vue from '@vitejs/plugin-vue'
  3. // https://vitejs.dev/config/
  4. export default defineConfig({
  5. server: {
  6. host: '0.0.0.0',
  7. proxy: {
  8. '/api': {
  9. target: "http://127.0.0.1:8800",
  10. changeOrigin: true,
  11. rewrite: path => path.replace(/^\/api/, '')
  12. }
  13. }
  14. },
  15. plugins: [vue()],
  16. })