import{n,s as t}from"./index-0d9f0c09.js";const e=[];function s(s,o=n){let c;const f=new Set;function i(n){if(t(s,n)&&(s=n,c)){const n=!e.length;for(const n of f)n[1](),e.push(n,s);if(n){for(let n=0;n{f.delete(r),0===f.size&&(c(),c=null)}}}}export{s as w};