Skip to content

Commit

Permalink
Update types in types/index.d.ts
Browse files Browse the repository at this point in the history
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)

The current types trigger an error:
```
node_modules/react-sortable-hoc/types/index.d.ts:108:11 - error TS2694: Namespace 'React' has no exported member 'SFC'.

108   | React.SFC<P>
```
  • Loading branch information
hpello authored Feb 15, 2023
1 parent caf3c4f commit 8937568
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export type WrappedComponentFactory<P> = (props: P) => JSX.Element;

export type WrappedComponent<P> =
| React.ComponentClass<P>
| React.SFC<P>
| React.FunctionCommponent<P>
| WrappedComponentFactory<P>;

export function SortableContainer<P>(
Expand Down

0 comments on commit 8937568

Please sign in to comment.