mirror of
https://github.com/15000rpm/Pole-Mapper.git
synced 2026-10-09 10:45:10 +09:00
26 lines
633 B
JavaScript
26 lines
633 B
JavaScript
import { defineConfig } from 'vite'
|
|
import react from '@vitejs/plugin-react'
|
|
import fs from 'fs'
|
|
import path from 'path'
|
|
|
|
// https://vite.dev/config/
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
server: {
|
|
host: true,
|
|
https: {
|
|
key: fs.readFileSync(path.join(process.env.USERPROFILE, '.vite-key.pem')),
|
|
cert: fs.readFileSync(path.join(process.env.USERPROFILE, '.vite-cert.pem')),
|
|
},
|
|
proxy: {
|
|
'/api': {
|
|
target: 'http://localhost:4000',
|
|
changeOrigin: true,
|
|
},
|
|
'/uploads': {
|
|
target: 'http://localhost:4000',
|
|
changeOrigin: true,
|
|
},
|
|
},
|
|
},
|
|
}) |