Skip to content
This repository was archived by the owner on Nov 27, 2023. It is now read-only.

Commit 72e1aa3

Browse files
authored
Merge pull request #468 from KnisterPeter/union-function-parentheses
fix: add parentheses around function in union by updating dts-dom
2 parents 55ea29e + baaa644 commit 72e1aa3

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
"babel-generator": "^6.26.0",
7070
"babylon": "7.0.0-beta.34",
7171
"chalk": "^2.3.0",
72-
"dts-dom": "^0.1.24",
72+
"dts-dom": "^0.1.25",
7373
"get-stdin": "^5.0.1",
7474
"meow": "^4.0.0",
7575
"pascal-case": "2.0.1",

tests/es6-class.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ declare module 'component' {
1212
fontSize?: number;
1313
}
1414

15-
export type ComponentRequiredUnion = any[] | boolean;
15+
export type ComponentRequiredUnion = ((...args: any[])=>any) | boolean;
1616

1717
export interface ComponentRequiredArrayOfObjectsWithShape {
1818
color?: string;

tests/es6-class.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Component.propTypes = {
3737
requiredFunc: React.PropTypes.func.isRequired,
3838
requiredAny: React.PropTypes.any.isRequired,
3939
requiredUnion: React.PropTypes.oneOfType([
40-
React.PropTypes.array,
40+
React.PropTypes.func,
4141
React.PropTypes.bool
4242
]).isRequired,
4343
requiredArrayOf: React.PropTypes.arrayOf(React.PropTypes.string).isRequired,

0 commit comments

Comments
 (0)