README
vite-plugin-external
Better to define externals in vite2. It not only work on our source code, but also work on pre-bundling dependencies well.

Installation
npm install vite-plugin-external --save-dev
Usage
import createExternal from 'vite-plugin-external';
export default defineConfig({
plugins: [
createExternal({
externals: {
react: 'React'
}
})
]
});
Override externals by mode
import createExternal from 'vite-plugin-external';
export default defineConfig({
plugins: [
createExternal({
externals: {
react: 'React'
},
development: {
externals: {
react: '$linkdesign.React'
}
}
})
]
});
