frequi_origin/vite.config.js
2022-02-05 20:13:18 +01:00

36 lines
692 B
JavaScript

import { defineConfig } from 'vite';
import { createVuePlugin } from 'vite-plugin-vue2';
import { resolve } from 'path';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [createVuePlugin()],
resolve: {
alias: [
{
find: '@',
replacement: resolve(__dirname, 'src'),
},
],
},
build: {
chunkSizeWarningLimit: 700, // Default is 500
sourcemap: true,
},
css: {
preprocessorOptions: {
scss: {
additionalData: '@import "@/styles/_variables.scss";',
},
},
},
server: {
proxy: {
'/api': {
target: 'http://127.0.0.1:8080',
changeOrigin: true,
},
},
},
});