11// Import dependencies.
22import resolve from 'rollup-plugin-node-resolve' ;
33import commonjs from 'rollup-plugin-commonjs' ;
4+ import replace from 'rollup-plugin-replace' ;
45import babel from 'rollup-plugin-babel' ;
56import uglify from 'rollup-plugin-uglify' ;
67import pkg from './package.json' ;
@@ -41,6 +42,7 @@ export default [
4142 plugins : [
4243 resolve ( ) ,
4344 commonjs ( ) ,
45+ replace ( { 'process.env.NODE_ENV' : JSON . stringify ( 'production' ) } ) ,
4446 babel ( { exclude : 'node_modules/**' } ) ,
4547 banner ( )
4648 ]
@@ -64,6 +66,7 @@ export default [
6466 plugins : [
6567 resolve ( ) ,
6668 commonjs ( ) ,
69+ replace ( { 'process.env.NODE_ENV' : JSON . stringify ( 'production' ) } ) ,
6770 babel ( { exclude : 'node_modules/**' } ) ,
6871 uglify ( {
6972 output : { preamble : banner ( ) . banner }
@@ -84,6 +87,7 @@ export default [
8487 plugins : [
8588 resolve ( ) ,
8689 commonjs ( ) ,
90+ replace ( { 'process.env.NODE_ENV' : JSON . stringify ( 'production' ) } ) ,
8791 babel ( { exclude : 'node_modules/**' } ) ,
8892 banner ( )
8993 ]
@@ -102,6 +106,7 @@ export default [
102106 plugins : [
103107 resolve ( ) ,
104108 commonjs ( ) ,
109+ replace ( { 'process.env.NODE_ENV' : JSON . stringify ( 'production' ) } ) ,
105110 babel ( { exclude : 'node_modules/**' } ) ,
106111 uglify ( {
107112 output : { preamble : banner ( ) . banner }
0 commit comments