The PAN Bus is a custom element that provides publish/subscribe and request/reply
messaging via DOM CustomEvents. Messages bubble and are composed, crossing shadow DOM
boundaries for true component isolation.

Class: PanBus

Extends: HTMLElement
The PAN Bus is a custom element that provides publish/subscribe and request/reply
messaging via DOM CustomEvents. Messages bubble and are composed, crossing shadow DOM
boundaries for true component isolation.
/
/**
/
/**
PAN Bus - Central message bus for Page Area Network
Handles message routing between components using CustomEvents. Supports:
- Publish/subscribe pattern
- Request/reply pattern
- Retained messages (last message per topic)
- Topic wildcards (e.g., "users.*")
- Shadow DOM traversal

Examples

// Add bus to page
<pan-bus></pan-bus>
// Or wait for it to be ready
document.addEventListener('pan:sys.ready', () => {
  console.log('PAN bus is ready');
});
/
/**