w3up icon indicating copy to clipboard operation
w3up copied to clipboard

Persisting a user-owned space over page reload in a web client

Open polus-arcticus opened this issue 1 year ago • 0 comments

https://github.com/storacha/w3up/tree/main/packages/w3up-client#user-owned

Hi, I've been workign through a user owned workflow and its working great. Ive been doing

    const prin = Signer.parse(privateKey)
    const sto = new StoreMemory()
    const cli = await Client.create({principal: prin, store: sto})
    const acc = await cli.login(email)
    await acc.plan.wait()
    const spa = await cli.createSpace(`user-space`, {account: acc})
    console.log(spa)
    localStorage.setItem('w3up', JSON.stringify({privateKey, email}))

however, I am finding that I need to re authorize my email every time. I'm wondering if there is a way to persist the session? thanks!

polus-arcticus avatar Nov 02 '24 17:11 polus-arcticus