You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
SoulSync/webui/vite.config.ts

32 lines
711 B

import { tanstackRouter } from '@tanstack/router-plugin/vite';
import react from '@vitejs/plugin-react';
import path from 'node:path';
import { defineConfig } from 'vite';
export default defineConfig({
plugins: [
tanstackRouter({
target: 'react',
}),
react(),
],
base: '/static/dist/',
root: import.meta.dirname,
resolve: {
alias: [
{
find: /^@\//,
replacement: `${path.resolve(import.meta.dirname, 'src')}/`,
},
],
},
build: {
outDir: path.resolve(import.meta.dirname, 'static/dist'),
emptyOutDir: true,
manifest: true,
rolldownOptions: {
input: [path.resolve(import.meta.dirname, 'src/app/main.tsx')],
},
},
});