Skip to content

Commit

Permalink
Merge pull request #15 from github/add-typescript-definition-file
Browse files Browse the repository at this point in the history
Add typescript definition file
  • Loading branch information
koddsson committed Aug 16, 2019
2 parents 5ac5b5a + cd1cc2a commit 4d003f0
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 @@ -16,7 +17,8 @@
"postpublish": "npm publish --ignore-scripts --@github:registry='https://npm.pkg.github.com'"
},
"files": [
"dist"
"dist",
"index.d.ts"
],
"keywords": [],
"author": "",
Expand Down

0 comments on commit 4d003f0

Please sign in to comment.