Skip to content

Commit dd793a4

Browse files
committed
fixed typscript typing
1 parent e60f87b commit dd793a4

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

dist/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ interface optionType {
55
interval?: number;
66
timeout?: number;
77
}
8-
export declare function useHoverIntent(options: optionType): (boolean | import("react").RefObject<HTMLElement>)[];
8+
export declare function useHoverIntent(options: optionType): [boolean, React.RefObject<HTMLElement>];
99
export {};

dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/package.json

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-use-hoverintent",
3-
"version": "1.2.0",
3+
"version": "1.2.1",
44
"description": "React hook for hoverIntent",
55
"main": "dist/index.js",
66
"module": "dist/index.js",
@@ -16,11 +16,15 @@
1616
"license": "MIT",
1717
"devDependencies": {
1818
"@babel/cli": "^7.12.1",
19+
"@babel/core": "^7.12.3",
20+
"@babel/preset-env": "^7.12.1",
21+
"@babel/preset-react": "^7.12.1",
22+
"@babel/preset-typescript": "^7.12.1",
1923
"@types/react": "^16.9.35",
2024
"copyfiles": "^2.4.0",
2125
"react": "^16.13.1",
2226
"rimraf": "^3.0.2",
23-
"typescript": "^3.9.2"
27+
"typescript": "^4.1.2"
2428
},
2529
"repository": "https://github.com/llldar/react-use-hoverintent",
2630
"peerDependencies": {
@@ -31,11 +35,5 @@
3135
],
3236
"scripts": {
3337
"build": "rimraf dist && tsc --emitDeclarationOnly && babel src --out-dir dist --extensions .ts,.tsx && copyfiles package.json LICENSE.md README.md ./dist"
34-
},
35-
"dependencies": {
36-
"@babel/core": "^7.12.3",
37-
"@babel/preset-env": "^7.12.1",
38-
"@babel/preset-react": "^7.12.1",
39-
"@babel/preset-typescript": "^7.12.1"
4038
}
4139
}

0 commit comments

Comments
 (0)