Probably a question for a maintainer but, On the v6 mantine website you can see slight flickering in the theme (light- to darkmode). I am experiencing this in my app where i store tabs in local storage, but this slight flicker where the state is the default key before set is causing a unneccesary fetch. I cannot see this issue in v7. Is this something that was fixed in v7 (could not se anything in the changelog). I am planning to schedule migrating the application in february, is there some "quick fix" i can do in the meantime.
#Issue with useLocalStorage "flickering"
1 messages · Page 1 of 1 (latest)
Yes, color scheme handling was changed in v7
But is the "issue" with useLocalStorage fixed in v7?
Or is there something else happening?
Color scheme is not managed with useLocalStorage hook in v7, there is no issue
Okay, but useLocalStorage will always have the defaultValue as value until the actual value is fetched, from storage?
This behavior is controlled by getInitialValueInEffect option
Oh great, ok, is there anything in the docs on that?
Thank you i just could not exactly understand the phrasing, what will the value be if set to true or false?