Skip to content

Commit

Permalink
Functions in the index.d.ts need to declare return types (#233)
Browse files Browse the repository at this point in the history
Otherwise Typescript will complain that they're assumed to be any
  • Loading branch information
almost authored Jan 9, 2023
1 parent 7b2f802 commit bb105bc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,11 @@ declare class Orientation {

export default Orientation;

declare function useOrientationChange(listener: (orientation: OrientationType) => void);
declare function useOrientationChange(listener: (orientation: OrientationType) => void): void;

declare function useDeviceOrientationChange(listener: (orientation: OrientationType) => void);
declare function useDeviceOrientationChange(listener: (orientation: OrientationType) => void): void;

declare function useLockListener(listener: (orientation: OrientationType) => void);
declare function useLockListener(listener: (orientation: OrientationType) => void): void;

export {
useOrientationChange,
Expand Down

0 comments on commit bb105bc

Please sign in to comment.