Skip to content

Commit 9301493

Browse files
Sebastian WendorfSebastian Wendorf
authored andcommitted
Added detection of React function components returning ReactNode
1 parent 631adf4 commit 9301493

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

typescript/src/react/post-processors/react-component.post-processor.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ export class ReactComponentPostProcessor extends PostProcessor {
6262
}
6363
}
6464

65+
/**
66+
* returns whether the provided fqn is a return type that indicates that a function is a React component
67+
*/
6568
function isComponentReturnType(globalFqn: string): boolean {
6669
return [
6770
'"react".React.ReactNode',

0 commit comments

Comments
 (0)