import{c as i}from"./mutative-C6xjlr6O.js";import{r as e}from"./main-few-lands-burn.js";function E(t,o){e.useRef({patches:[],inversePatches:[]});const n=e.useRef(0),s=e.useRef(0);let r=n.current;e.useEffect((()=>{n.current=r,s.current=r})),r+=1,s.current+=1;const[f,u]=e.useState((()=>typeof t=="function"?t():t)),a=e.useCallback((c=>{u((p=>i(p,typeof c=="function"?c:()=>c,o)))}),[]);return e.useEffect((()=>{})),[f,a]}export{E as a};
