   => {
const [count, setCount] = React.useState(0);
const [post] = useBroadcastChannel
const handler = () => {
post(count + 1);
setCount(count => count + 1);
}
return (
What is BroadcastChannel API?
BroadcastChannel API allows to communicate between browsing contexts such as iframes, browser tabs, or even workers on the same origin.API
$3
`ts
const [post] = useBroadcastChannel('channel-id', event => event.data)
``