Skip to content

Commit bb105bc

Browse files
authoredJan 9, 2023
Functions in the index.d.ts need to declare return types (#233)
Otherwise Typescript will complain that they're assumed to be any
1 parent 7b2f802 commit bb105bc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

‎index.d.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,11 @@ declare class Orientation {
8282

8383
export default Orientation;
8484

85-
declare function useOrientationChange(listener: (orientation: OrientationType) => void);
85+
declare function useOrientationChange(listener: (orientation: OrientationType) => void): void;
8686

87-
declare function useDeviceOrientationChange(listener: (orientation: OrientationType) => void);
87+
declare function useDeviceOrientationChange(listener: (orientation: OrientationType) => void): void;
8888

89-
declare function useLockListener(listener: (orientation: OrientationType) => void);
89+
declare function useLockListener(listener: (orientation: OrientationType) => void): void;
9090

9191
export {
9292
useOrientationChange,

0 commit comments

Comments
 (0)