The onremove lifecycle hook runs on top level components, but when their descendants are also removed as a result of the parent being removed, their onremoves are never called.
FWIW, i've gone through this issue in my own lib [1].
In the end I had to give up some removal optimizations and always do bottom-up removal in case there are deep lifecycle hooks to trigger. It gets even more hairy when those hooks can invoke async css transitions to animate out [2], delaying parent removal until resolution (i don't handle this case as it is complex and uncommon). It doesn't help that domvm also has node-level hooks, besides component-level hooks :/
Some things to consider ;)
[1] https://github.com/leeoniya/domvm
[2] https://leeoniya.github.io/domvm/demos/lifecycle-hooks.html
fixed in 519b352c2c05ae7e7a94f23ace60c8d47dbad540
Most helpful comment
fixed in 519b352c2c05ae7e7a94f23ace60c8d47dbad540