mirror of
https://gitee.com/newgateway/vtj.git
synced 2026-05-08 12:17:27 +08:00
15 lines
395 B
TypeScript
15 lines
395 B
TypeScript
import { createViteConfig, createPluginViteConfig, readJson } from '@vtj/cli';
|
|
import { createDevTools } from '@vtj/pro/vite';
|
|
const isUmd = !!process.env.UMD;
|
|
const isDev = !!process.env.DEV;
|
|
const pkg = readJson('package.json');
|
|
|
|
export default isDev
|
|
? createViteConfig({
|
|
plugins: [createDevTools()]
|
|
})
|
|
: createPluginViteConfig({
|
|
libFileName: pkg.name,
|
|
isUmd
|
|
});
|