-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Description
I am proposing that the instrumentations developed by the browser SIG adopt a pure zoneless policy in favor of explicit and stack context propagation.
Steps
- Remove any implicit or explicit zone dependencies. Do not include it in any default browser bundles.
- an implicit dependency would be any instrumentation that calls
context.*API functions which assume there is an async context implementation available
- an implicit dependency would be any instrumentation that calls
- Internally, instrumentations should manually handle explicit context
- Instrumentations should use the synchronous
StackContextManagerto re-establish context at continuation boundaries. If the user has registered the zone context manager these will continue to work. It may be useful to publish a small helper library for common tasks like binding promises or event emitters.
Benefits
- Reduced bundle size
- Avoids zone.js patching and its overhead
- Explicit re-entry points make context propagation easier to reason about and debug
- Works in apps that cannot or will not include zone.js
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels