import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import vueJsx from '@vitejs/plugin-vue-jsx'
import VueMacros from 'unplugin-vue-macros/vite'
// https://vitejs.dev/config/
export default defineConfig({
    server: {
        port: 6868,
        proxy: {
            '/demoServer': {
                target: 'https://test.4dkankan.com',
                changeOrigin: true,
                rewrite: (path) => path.replace(/^\/demoServer/, ''),
            },
        },
    },
    plugins: [
        //@ts-ignore
        VueMacros({
            setupComponent: false,
            setupSFC: false,
            plugins: {
                vue: vue(),
                vueJsx: vueJsx(),
            },
        }),
    ],
})
