You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current implementation hardcodes the supported event types. Whenever a new event type (e.g., ErrorEvent, AuditEvent) is added, the dispatchEvent method must be modified.
If the number of event types increases or becomes more granular in the future, it's easy to miss handling certain branches.
A more elegant approach should be used—one that allows each event to determine its own handling logic, eliminating the need for hardcoded type checks and avoiding missing branches. This way, potential issues can be caught at compile time.
The text was updated successfully, but these errors were encountered:
What would you like to be improved?
Current implementation lacks elegance.
How should we improve?
A more elegant approach should be used—one that allows each event to determine its own handling logic, eliminating the need for hardcoded type checks and avoiding missing branches. This way, potential issues can be caught at compile time.
The text was updated successfully, but these errors were encountered: