I created a simple typescript react app with react-create-app
library.
After that, I installed reactstrap and bootsrap and tried implement a simple reacstrap button to my code
import React from 'react';
import {Button} from "reactstrap";
import 'bootstrap/dist/css/bootstrap.min.css';
function App () {
return <Button>Button</Button>;
}
export default App;
After start I got the error
'Button' cannot be used as a JSX component.
Its instance type 'Button' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("/Users/krolov/work/node_modules/@types/react/index").ReactNode'.
Type 'ReactElement<any, string | JSXElementConstructor<any>>' is not assignable to type 'ReactNode'.
Property 'children' is missing in type 'ReactElement<any, string | JSXElementConstructor<any>>' but required in type 'ReactPortal'.