Please think of all the things you're losing by doing this. I've never encountered the need, and it strikes me as something you should jump through hoops to avoid.
In the normal case, your template is a dumb stable thing that closely ressembles the output, with holes for dynamic data (supplied via reactivity) and some event handlers that will eventually update your model. It tells you everything it will call.
If you have some code somewhere that dynamically attaches event handlers, or modifies their behaviour, you no longer have that certainty. You attach your handlers in response to what? Your app now has modes, which are bad. I would much rather have static, permanently attached, declared in the template, event handlers, then deal with your requirement by putting conditionals in the handlers.