Open SukkaW opened 2 years ago
The issue is similar to the one in the jotai: https://github.com/pmndrs/jotai/issues/1158#issuecomment-1126839533
Is it possible to apply a fix similar to https://github.com/pmndrs/jotai/pull/1159, to prevent atoms with the same primitive value from unnecessary committing?
No, it's not possible because we always run update function in render phase. And, thus, side effects are not allowed in the update function.
The issue is similar to the one in the jotai: https://github.com/pmndrs/jotai/issues/1158#issuecomment-1126839533
Is it possible to apply a fix similar to https://github.com/pmndrs/jotai/pull/1159, to prevent atoms with the same primitive value from unnecessary committing?