pad.libre-service.eu-etherpad/admin/vite.config.ts
SamTV12345 e12be96102
feat(admin): Added shoutout to admin panel (#6346)
* Added shoutout

* Added shoutout function

* Fixed test.

* Included feedback from review.

* Removed unnecessary file
2024-04-21 17:58:51 +02:00

38 lines
920 B
TypeScript

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react-swc'
import svgr from 'vite-plugin-svgr'
import {viteStaticCopy} from "vite-plugin-static-copy";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react(), svgr(), viteStaticCopy({
targets: [
{
src: '../src/locales',
dest: ''
}
]
})],
base: '/admin',
build:{
outDir: '../src/templates/admin',
emptyOutDir: true,
},
server:{
proxy: {
'/socket.io/*': {
target: 'http://localhost:9001',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
},
'/admin-auth/': {
target: 'http://localhost:9001',
changeOrigin: true,
},
'/stats': {
target: 'http://localhost:9001',
changeOrigin: true,
}
}
}
})