-
-
Notifications
You must be signed in to change notification settings - Fork 242
Expand file tree
/
Copy pathvite.config.ts
More file actions
36 lines (35 loc) · 1009 Bytes
/
vite.config.ts
File metadata and controls
36 lines (35 loc) · 1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import tailwindcss from '@tailwindcss/vite'
import react from '@vitejs/plugin-react'
import rsc from '@vitejs/plugin-rsc'
import { defineConfig } from 'vite'
export default defineConfig({
clearScreen: false,
build: {
minify: false,
},
plugins: [
// import("vite-plugin-inspect").then(m => m.default()),
tailwindcss(),
{
// TODO: quick workaround for https://github.com/tailwindlabs/tailwindcss/pull/19670
name: 'fix-tailwind-full-reload',
configResolved(config) {
const plugin = config.plugins.find(
(p) => p.name === '@tailwindcss/vite:generate:serve',
)
delete plugin?.hotUpdate
},
},
react(),
rsc({
entries: {
client: './react-router-vite/entry.browser.tsx',
ssr: './react-router-vite/entry.ssr.tsx',
rsc: './react-router-vite/entry.rsc.single.tsx',
},
}),
],
optimizeDeps: {
include: ['react-router', 'react-router/internal/react-server-client'],
},
}) as any