import{useEffect as c,useState as a}from"react";import{AppConfig as i,UserSession as d}from"@stacks/connect";var f=()=>{let[o,t]=a(""),r=new i(["store_write","publish_data"]),s=new d({appConfig:r}),n=()=>{s.signUserOut(),t("")};return c(()=>{if(s)try{let e=s.loadUserData();t(e.profile.stxAddress.testnet)}catch(e){}},[s]),{stacksAddress:o,userSession:s,disconnectStacks:n}},k=f;export{k as default};
