On this page I used next code:
<div>
<button id="withoutZone">3 handlers without Zonejs</button>
<button id="withZone">3 handlers with Zonejs</button>
</div>
<script>
withoutZone.addEventListener('click', () => {
console.error('[without Zone]: handler 1.');
throw new Error('Error from first handler without Zonejs');
});
withoutZone.addEventListener('click', () => {
console.error('[without Zone]: handler 2.');
});
withoutZone.addEventListener('click', () => {
console.error('[without Zone]: handler 3.');
});
</script>
<script type="text/javascript" src="https://unpkg.com/zone.js"></script>
<script>
withZone.addEventListener('click', () => {
console.error('[with Zone]: handler 1.', Zone.current);
throw new Error('Error from first handler with Zonejs');
});
withZone.addEventListener('click', () => {
console.error('[with Zone]: handler 2.');
});
withZone.addEventListener('click', () => {
console.error('[with Zone]: handler 3.');
});
</script>