Here is an example of the issue. If we tried to go to the path /cars/details from /cars this will fire that event listener and work. The route for cars would be product and for details that would be action. Now if we then tried to go to /cars/color from /cars/details this will not fire that event listener.
This only seems to fire if the actual route changes, not the path. Is there something I can do that can also detect a path change? I had tried using route.data.on but that did not seem to work.
I’d like us to decide if we want to document that (or make another official API), or document another way of accomplishing the same result (as a getter in a DefineMap, with can-value, etc.).
Inspired by @pmoscuzza-tc’s question on Slack:
Someone else asked a similar question recently too.
It looks like we added a private
__url
event that can be listened to: https://github.com/canjs/can-route/pull/80#issuecomment-304069436I’d like us to decide if we want to document that (or make another official API), or document another way of accomplishing the same result (as a getter in a DefineMap, with can-value, etc.).