diff options
Diffstat (limited to '.config/rollup.polyfills.js')
-rw-r--r-- | .config/rollup.polyfills.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/.config/rollup.polyfills.js b/.config/rollup.polyfills.js new file mode 100644 index 0000000..1df059a --- /dev/null +++ b/.config/rollup.polyfills.js @@ -0,0 +1,22 @@ +import resolve from 'rollup-plugin-node-resolve' +import commonjs from 'rollup-plugin-commonjs' +import { terser } from 'rollup-plugin-terser' +import filesize from 'rollup-plugin-filesize' + +// We dont need babel. All polyfills are compatible +const config = (ie) => ({ + input: ie ? './.config/polyfillListIE.js' : './.config/polyfillList.js', + output: { + file: ie ? 'dist/polyfillsIE.js' : 'dist/polyfills.js', + sourceMap: false, + format: 'iife' + }, + plugins: [ + resolve({ browser: true }), + commonjs(), + terser(), + filesize() + ] +}) + +export default [false, true].map(config) |