Yes the "on-escape" component just attaches an escape handler to the document. One of the reasons for it is just to not have to write that code yet another time, since doing that is boring and, more importantly, prone to bugs.
But the other reason is that it turns this:
document.attachEventListener('escape', fn, false);
into this: onEscape(fn);
without losing any clarity whatsoever.It's also more performant than attaching tons of different escape handlers, because across all components everyone will share the same event listener. Even for components that somebody else wrote and you're just using.
So yes, there's a component just for onEscape.