mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat(@vant/cli): generate cjs output (#9942)
This commit is contained in:
parent
249a8b64e2
commit
cfcc84ff25
@ -17,6 +17,7 @@ export function getViteConfigForPackage(minify: boolean): InlineConfig {
|
||||
lib: {
|
||||
name,
|
||||
entry: join(ES_DIR, 'index.js'),
|
||||
formats: ['es', 'cjs', 'umd'],
|
||||
fileName: (format: string) => {
|
||||
const suffix = format === 'umd' ? '' : `.${format}`;
|
||||
return minify ? `${name}${suffix}.min.js` : `${name}${suffix}.js`;
|
||||
|
Loading…
x
Reference in New Issue
Block a user