buster/apps/web-tss/vite.config.ts

32 lines
744 B
TypeScript
Raw Normal View History

2025-08-13 03:21:24 +08:00
import tailwindcss from '@tailwindcss/vite';
import { tanstackStart } from '@tanstack/react-start/plugin/vite';
import viteReact from '@vitejs/plugin-react';
import { defineConfig } from 'vite';
2025-08-13 04:07:06 +08:00
import checker from 'vite-plugin-checker';
2025-08-13 03:21:24 +08:00
import viteTsConfigPaths from 'vite-tsconfig-paths';
2025-08-12 11:28:36 +08:00
const config = defineConfig({
2025-08-13 00:30:48 +08:00
server: {
2025-08-13 04:07:06 +08:00
port: 3000,
2025-08-13 00:30:48 +08:00
},
2025-08-12 11:28:36 +08:00
plugins: [
// this is the plugin that enables path aliases
viteTsConfigPaths({
2025-08-13 04:07:06 +08:00
projects: ['./tsconfig.json'],
2025-08-12 11:28:36 +08:00
}),
tailwindcss(),
tanstackStart({
2025-08-13 04:07:06 +08:00
customViteReactPlugin: true,
2025-08-12 11:28:36 +08:00
}),
2025-08-13 04:07:06 +08:00
viteReact(),
2025-08-13 12:37:41 +08:00
!process.env.VITEST
? checker({
typescript: true,
biome: true,
})
: undefined,
2025-08-13 04:07:06 +08:00
],
2025-08-12 11:28:36 +08:00
});
export default config;