secutorpro commited on
Commit
ac32264
·
verified ·
1 Parent(s): ce82e20

vite config with dev proxy to the server

Browse files
Files changed (1) hide show
  1. web/vite.config.js +12 -0
web/vite.config.js ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { defineConfig } from 'vite';
2
+ import react from '@vitejs/plugin-react';
3
+
4
+ export default defineConfig({
5
+ plugins: [react()],
6
+ server: {
7
+ proxy: {
8
+ '/api': 'http://localhost:8080',
9
+ '/ws': { target: 'ws://localhost:8080', ws: true },
10
+ },
11
+ },
12
+ });