I have this code.
effect(() => {
productsShoes.value = shoes.value
})
I want to, everytime only, shoes.value is changed, trigger this effect. The way that is, its re-rendering, either both of signals are changed.
The logic that I want to achieve is like this with useEffect reacts hook:
useEffect(() => {
productsShoes.value = shoes.value
}, [shoes.value])
First of all, thank you for your attention!
https://preactjs.com/guide/v10/signals/#effectfn
which means that for your case prefer useSignalEffect, no need to pass any dependency, it will already track your changes and run automatically