Stream Creation from Objects with on/off

Is there something like Stream.fromEventListener but for objects that use on/off or just callbacks instead? In Electron code, for example on and
off
are everywhere on Electron-provided objects.
Was this page helpful?