vite.config.js 508 B

1234567891011121314151617181920212223242526
  1. import { fileURLToPath, URL } from 'node:url'
  2. import { defineConfig } from 'vite'
  3. import vue from '@vitejs/plugin-vue'
  4. import vueDevTools from 'vite-plugin-vue-devtools'
  5. // https://vite.dev/config/
  6. export default defineConfig({
  7. plugins: [
  8. vue(),
  9. vueDevTools(),
  10. ],
  11. resolve: {
  12. alias: {
  13. '@': fileURLToPath(new URL('./src', import.meta.url))
  14. },
  15. },
  16. server: {
  17. port: 9021,
  18. open: true,
  19. host: '0.0.0.0',
  20. proxy: {
  21. '^/api': 'http://127.0.0.1:9020',
  22. }
  23. },
  24. })