Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
Pessimistress committed Dec 8, 2024
1 parent 4bc3dca commit 8bff72b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/event-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ export class EventManager {
opts = handler;
// If `event` is a map, call `on()` for each entry.
for (const [eventName, eventHandler] of Object.entries(event)) {
this._addEventHandler(eventName, eventHandler!, opts, once, passive);
this._addEventHandler(eventName, eventHandler, opts, once, passive);
}
return;
}
Expand Down
4 changes: 3 additions & 1 deletion src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,9 @@ export type MjolnirEvent =
| MjolnirWheelEvent
| MjolnirKeyEvent;

export type MjolnirEventHandler<EventT extends MjolnirEvent = MjolnirEvent> = (event: EventT) => void;
export type MjolnirEventHandler<EventT extends MjolnirEvent = MjolnirEvent> = (
event: EventT
) => void;

export type MjolnirEventHandlers = {
[type: string]: MjolnirEventHandler;
Expand Down

0 comments on commit 8bff72b

Please sign in to comment.