by onsclom · 3y ago · 0 comments
Example: https://www.solidjs.com/examples/counter
`onMount` and `onDestroy` feel like really useful, dependable callbacks. `$effect` is scary because if you add a reference to state in it, you can't depend on it being called like `onMount`.
They claim most (but not all) of current usage of `onMount` will be better off using `$effect` instead