reanimated-color-picker
reanimated-color-picker copied to clipboard
[Reanimated] Reading from `value` during component render.
I'm using color picker in a very boring way:
<ColorPicker>
<Preview />
<Panel1 />
<HueSlider />
<Swatches />
</ColorPicker>
Nonetheless I'm generating a warning on every render:
hook.js:608 [Reanimated] Reading from `value` during component render. Please ensure that you do not access the `value` property or use `get` method of a shared value while React is rendering a component.
If you don't want to see this message, you can disable the `strict` mode. Refer to:
https://docs.swmansion.com/react-native-reanimated/docs/debugging/logger-configuration for more details.
I tried replicating this using your example but didn't see the warning. Since the warning doesn’t specify where it originates, it could be coming from somewhere else in your codebase. For example, accessing a SharedValue during render like <ColorPicker value={selectedColor.value} /> can trigger it.
Preview component caused this. I fixed it in the latest PR.