This repository was archived by the owner on May 22, 2025. It is now read-only.
This repository was archived by the owner on May 22, 2025. It is now read-only.
ZoneAwarePromise vs disambiguate_properties (type aware optimization) #198
Open
Description
Angular 2 uses Zone JS, which re-implements Promise
, including "static" functions like Promise.all
. This does not seem to play well with --disambiguate_properties
and --ambiguate_properties
. Closure removes the .all
implementation, Zone still patches the global Promise
object, and then user code fails when it calls Promise.all
as the function is no longer present.
I'm not sure what the best fix is, or if this is something tsickle can handle at all. Currently the tsickle-with-types emitted code doesn't even @implements
Promise
or IThenable
, but even if so, I would presume the "static" method would be removed, as Closure doesn't understand inheriting static properties?