16 lines
382 B
TypeScript
16 lines
382 B
TypeScript
|
|
import { defineConfig } from 'vite'
|
||
|
|
import react from '@vitejs/plugin-react'
|
||
|
|
|
||
|
|
export default defineConfig({
|
||
|
|
plugins: [react()],
|
||
|
|
server: {
|
||
|
|
proxy: {
|
||
|
|
// Cualquier petición que el frontend haga a /api/...
|
||
|
|
'/api': {
|
||
|
|
// ...Vite la redirigirá a nuestro backend de .NET
|
||
|
|
target: 'http://localhost:5036',
|
||
|
|
changeOrigin: true,
|
||
|
|
},
|
||
|
|
}
|
||
|
|
}
|
||
|
|
})
|