Skip to content

Commit

Permalink
Add typescript type definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
iansu authored and Darcy Clarke committed Nov 10, 2020
1 parent b025546 commit 8fd330b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
declare module 'sleepover' {
export function atomics(): boolean;
export function sleep(time: number): 'ok' | 'timed-out' | 'not-equal';
export function snooze(time: number): Promise<void>;
export function over(num: number, cb: () => void): void;
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"url": "darcyclarke.me"
},
"main": "./index.js",
"types": "./index.d.ts",
"engines": {
"node": ">=4"
},
Expand Down

0 comments on commit 8fd330b

Please sign in to comment.