Skip to content

Commit

Permalink
add typescript definition file
Browse files Browse the repository at this point in the history
  • Loading branch information
koddsson committed Jul 2, 2019
1 parent b20310e commit 7487d4e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions index.d.ts
@@ -0,0 +1,3 @@
export function install(container: Element, hotkey?: string): void;
export function uninstall(container: Element): void;
export function eventToHotkeyString(event: Event): string;
4 changes: 3 additions & 1 deletion package.json
Expand Up @@ -4,6 +4,7 @@
"description": "",
"main": "dist/index.umd.js",
"module": "dist/index.esm.js",
"types": "index.d.ts",
"repository": "github/hotkey",
"scripts": {
"build": "rollup -c && cp src/index.js.flow dist/index.esm.js.flow && cp src/index.js.flow dist/index.umd.js.flow",
Expand All @@ -15,7 +16,8 @@
"prepublishOnly": "npm run build"
},
"files": [
"dist"
"dist",
"index.d.ts"
],
"keywords": [],
"author": "",
Expand Down

0 comments on commit 7487d4e

Please sign in to comment.