Add type docs for NextComponentType type.

This commit is contained in:
João Vieira
2018-09-19 17:01:02 +01:00
parent 0f4418007c
commit 5be1841543

View File

@@ -180,6 +180,10 @@ declare namespace next {
/**
* Next.js counterpart of React.ComponentType.
* Specially useful in HOCs that receive Next.js components.
*
* @template P Component props.
* @template IP Initial props returned from getInitialProps.
* @template C Context passed to getInitialProps.
*/
type NextComponentType<P = {}, IP = P, C = NextContext> =
| NextComponentClass<P, IP, C>