Fork me on GitHub
#reagent
<
2023-01-03
>
Chris McCormick09:01:05

I frequently run into a situation using Alan Dipert's local-storage where I have my entire app state in one atom but I only want to persist a certain subset of the atom into localStorage. I solved this by forking local-storage and adding functions for selecting which keys to persist. I also tested wrapping a Reagent cursor in local-storage but it didn't work because the cursor data is not persisted when the higher level atom is swapped (only when the cursor itself is swapped). Is there some more elegant method I am missing?