News for hackers. Stuff that matters.
Re:A guide to useEffect in React by littlecranky67 on Monday March 11, 2019 @08:26AM (#19358406)
This is no different when using Hooks. You specify the type of props as the type of the first argument in the functional component:

  function MyComponent(props: IMyComponentProps) { ... }
Where the type definition of IMyComponentProps resides doesn't matter, you can import it from anywhere.
Re:A guide to useEffect in React by teniutza on Tuesday March 12, 2019 @05:11AM (#19366453)
I was simply pointing out that explicitly defining an interface is not necessarily a downside.