Angular 4 put a global constant available to zone.js

Viewed 8208

i am using Angular (4 i think) with typescript and zone.js (0.8.4). I import zone.js via the "polyfills.ts" file. When I look inside the source code of zone.js, there is code like this:

var isDisableIECheck = _global['__Zone_disable_IE_check'] || false;

My question is, how can I set this variable in _globals ?

Thanks

2 Answers

In my case, I have had to uncomment the following line in the polyfills file:

(window as any).__Zone_enable_cross_context_check = true;

Project Angular version: Angular 6.0.1

Related