File tree 1 file changed +16
-0
lines changed
1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,22 @@ import bindActionCreators from './utils/bindActionCreators'
4
4
import applyMiddleware from './utils/applyMiddleware'
5
5
import compose from './utils/compose'
6
6
7
+ /*
8
+ * create a function so that we can check if the function name has been atlered by minification
9
+ * if the function has been minified and NODE_ENV !== 'production', warn the user
10
+ */
11
+ function isCrushed ( ) { }
12
+
13
+ if ( isCrushed . name !== 'isCrushed' && process . env . NODE_ENV !== 'production' ) {
14
+ /*eslint-disable no-console */
15
+ console . error ( 'You are utilzing minified code outside of NODE_ENV === \'production\'. ' +
16
+ 'This means that you are running a slower development only build of Redux. ' +
17
+ 'Consult tools such as loose-envify (https://github.com/zertosh/loose-envify) for browserify ' +
18
+ 'and DefinePlugin for webpack (http://stackoverflow.com/questions/30030031) ' +
19
+ 'to build with proper NODE_ENV' )
20
+ /*eslint-enable */
21
+ }
22
+
7
23
export {
8
24
createStore ,
9
25
combineReducers ,
You can’t perform that action at this time.
0 commit comments