Open hpello opened 1 year ago
Hello @joshwnj! Could you take a look at this PR? 🙂
We need it to keep using react-visibility-sensor
in our TS codebase.
@joshwnj StatelessComponent
was deprecated in react v17 and removed in v18. Could you please merge this change? https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/react/v17/index.d.ts#L537
Description
The current types trigger an error:
Indeed,
React.StatelessComponent
has been removed from the react types (see https://stackoverflow.com/questions/44375759/how-should-i-declare-a-stateless-functional-component-with-typescript-in-react)This PR fixes this error.