File tree 1 file changed +7
-5
lines changed
1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -16,8 +16,14 @@ declare function instanceOf(
16
16
constructor : mixed ,
17
17
) : boolean % checks ( value instanceof constructor ) ;
18
18
19
- export default ( process && process . env . NODE_ENV !== 'production'
19
+ // See: https://expressjs.com/en/advanced/best-practice-performance.html#set-node_env-to-production
20
+ // See: https://webpack.js.org/guides/production/
21
+ export default ( process . env . NODE_ENV === 'production'
20
22
? // eslint-disable-next-line no-shadow
23
+ function instanceOf ( value : any , constructor : any ) {
24
+ return value instanceof constructor ;
25
+ }
26
+ : // eslint-disable-next-line no-shadow
21
27
function instanceOf ( value : any , constructor : any ) {
22
28
if ( value instanceof constructor ) {
23
29
return true ;
@@ -43,8 +49,4 @@ spurious results.`,
43
49
}
44
50
}
45
51
return false ;
46
- }
47
- : // eslint-disable-next-line no-shadow
48
- function instanceOf ( value : any , constructor : any ) {
49
- return value instanceof constructor ;
50
52
} ) ;
You can’t perform that action at this time.
0 commit comments