import {terser} from 'rollup-plugin-terser'; import {nodeResolve} from '@rollup/plugin-node-resolve'; export default { input: 'src/main-libs.js', output: [ { dir: 'dist', entryFileNames: 'libs.js', format: 'cjs' }, { dir: 'dist', entryFileNames: 'libs.min.js', format: 'cjs', plugins: [terser()] } ], context: 'this', plugins: [nodeResolve()] }