Is it possible to have two tabs open using the same app without overwriting each others state?
josoroma-zz opened this issue · 2 comments
josoroma-zz commented
Hi!
I have this app where people needs to have one tab open as a user and another tab open as a admin... So I was wondering if it is possible to have two tabs open using the same application without overwriting the other's state?
Thank you!
polemius commented
Hi,
It is possible in your application to change the key for different user role?
const { persistAtom } = recoilPersist({
key: isAdmin ? 'recoil-persist-admin' : 'recoil-persist-user',
})
josoroma-zz commented
Thanks a bunch @polemius !