Ignore Model Store Persistence ? #1815
Answered
by
jamonholmgren
RadouaneEzzaggab
asked this question in
Q&A
-
Hello guys, sorry for my bad english. Pls, How can i ignore one of my model store from data storage ? |
Beta Was this translation helpful? Give feedback.
Answered by
jamonholmgren
Oct 18, 2021
Replies: 1 comment 2 replies
-
Hey @RadouaneEzzaggab, thanks for the question! You can ignore sections by editing this: ignite/boilerplate/app/models/root-store/setup-root-store.ts Lines 51 to 52 in d900ef5 Something like this (not tested): // track changes & save to storage
onSnapshot(rootStore, (snapshot) => {
// remove `someModel` from stored snapshot
const { someModel, ...newSnapshot } = snapshot
storage.save(ROOT_STATE_STORAGE_KEY, newSnapshot)
}) |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
jamonholmgren
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey @RadouaneEzzaggab, thanks for the question!
You can ignore sections by editing this:
ignite/boilerplate/app/models/root-store/setup-root-store.ts
Lines 51 to 52 in d900ef5
Something like this (not tested):