Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upMany events triggered with undocumented Event arg #19156
Comments
This comment has been minimized.
This comment has been minimized.
|
If that's the case, we would welcome PRs to correct said documentation! I can also potentially dedicate some time to auditing and addressing this gap time permitting. |
This comment has been minimized.
This comment has been minimized.
|
So what you're saying is that the runtime behaviour is correct, and that if an event is called with |
This comment has been minimized.
This comment has been minimized.
|
In any case: While I can write down the events I come across and can test, and even submit a doc PR time permitting, I'm new to Electron and don't have the infrastructure (e.g. for auto-update) or devices (e.g. for macOS-only events) to test all events. So ideally I'd like to get some official answers and not have to guess. :) |
I'm confused about events, specifically runtime vs. documented listener signatures. Many events are documented without an
Eventparameter, for example many of the BrowserWindow events such asclosed,bluretc. But at runtime, these events are called with anEventparameter.This made me think that maybe all events have
Eventas the first parameter, but some events, such as theautoUpdatererrorevent is only called withError, notEvent(and is correctly documented).Is this just a matter of incomplete documentation, or is there a logic to this? (I'm new to the JS world, so please bear with me if this is evident to everyone but me.)
(If anyone is wondering; I'm creating Electron bindings for Fable, an F# to JS compiler, and since F# is strongly typed I should get this right in the bindings.)