mirror of
https://github.com/tale/headplane.git
synced 2026-08-21 10:16:37 +00:00
fix: do not bundle ssr deps in dev
This commit is contained in:
+3
-3
@@ -18,7 +18,7 @@ if (!version) {
|
|||||||
throw new Error('Unable to read version from package.json');
|
throw new Error('Unable to read version from package.json');
|
||||||
}
|
}
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig(({ isSsrBuild }) => ({
|
||||||
// base: `${prefix}/`,
|
// base: `${prefix}/`,
|
||||||
plugins: [reactRouterHonoServer(), reactRouter(), tsconfigPaths()],
|
plugins: [reactRouterHonoServer(), reactRouter(), tsconfigPaths()],
|
||||||
css: {
|
css: {
|
||||||
@@ -28,10 +28,10 @@ export default defineConfig({
|
|||||||
},
|
},
|
||||||
ssr: {
|
ssr: {
|
||||||
target: 'node',
|
target: 'node',
|
||||||
noExternal: true,
|
noExternal: isSsrBuild ? true : undefined,
|
||||||
},
|
},
|
||||||
define: {
|
define: {
|
||||||
__VERSION__: JSON.stringify(version),
|
__VERSION__: JSON.stringify(version),
|
||||||
__PREFIX__: JSON.stringify(prefix),
|
__PREFIX__: JSON.stringify(prefix),
|
||||||
},
|
},
|
||||||
});
|
}));
|
||||||
|
|||||||
Reference in New Issue
Block a user