Wouldn't logging action processing be helpful?

I’ve found action handling to be fairly tricky, especially when using nested components. I was thinking it might be helpful to have conditional logging of the bubbling/target-lookup process, so you can see what you may have missed if your handler is not firing.

Thoughts?

3 Likes

You mean similar to what APP.LOG_TRANSITIONS does? So APP.LOG_ACTIONS? Sounds reasonable. You could also at least implement something similar using Ember’s Logger for now: Ember - 4.6 - Ember API Documentation

I was thinking this would be in the ember internals, where each time an action was triggered, and it searches for a target, calls an action method, etc., it would be logged, most importantly when it was not found and where it was looking. It seems like any time an action is not handled, you probably want to know the last place it was dropped.