config-min.js 394 B

1234567891011121314151617181920
  1. const config = require( './config' );
  2. const TerserPlugin = require( 'terser-webpack-plugin' );
  3. module.exports = {
  4. ...config,
  5. output : {
  6. filename: 'splide.min.js',
  7. },
  8. optimization: {
  9. minimize : true,
  10. minimizer: [ new TerserPlugin( {
  11. terserOptions: {
  12. format: {
  13. comments: /^\**!|@preserve|@license|@cc_on/i,
  14. },
  15. },
  16. extractComments: false,
  17. } ) ],
  18. },
  19. };