2021-07-29 21:48:46 +02:00
|
|
|
import { jsConfig } from './webpack.config.base';
|
2017-04-16 21:38:48 +08:00
|
|
|
|
2021-10-01 02:26:42 +05:30
|
|
|
const umdConfig = jsConfig();
|
|
|
|
umdConfig.mode = 'production';
|
|
|
|
umdConfig.output.filename = '[name].min.js';
|
2017-04-16 21:38:48 +08:00
|
|
|
|
2021-10-01 02:26:42 +05:30
|
|
|
const esmConfig = jsConfig();
|
|
|
|
esmConfig.mode = 'production';
|
|
|
|
esmConfig.output.library = {
|
|
|
|
type: 'module',
|
|
|
|
};
|
|
|
|
esmConfig.experiments = {
|
|
|
|
outputModule: true,
|
|
|
|
};
|
2021-10-01 19:19:32 +05:30
|
|
|
esmConfig.output.filename = '[name].esm.min.mjs';
|
2021-10-01 02:26:42 +05:30
|
|
|
|
|
|
|
export default [umdConfig, esmConfig];
|