vite/playground/ssr-noexternal/vite.config.js
patak 757844f0bd
refactor: remove build time pre-bundling (#15184)
Co-authored-by: 翠 / green <green@sapphi.red>
Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
2024-01-15 14:29:54 +01:00

20 lines
388 B
JavaScript

import { defineConfig } from 'vite'
const noExternal = ['@vitejs/test-require-external-cjs']
export default defineConfig({
ssr: {
noExternal,
external: ['@vitejs/test-external-cjs'],
optimizeDeps: {
include: noExternal,
},
},
build: {
target: 'esnext',
minify: false,
rollupOptions: {
external: ['@vitejs/test-external-cjs'],
},
},
})