In my typescript/reactjs app I am trying to pass in a property called test like this, this is part of the index.tsx:
ReactDOM.render(
<Provider store={getStore()}>
<BrowserRouter>
<App test={1} />
</BrowserRouter>
</Provider>,
document.getElementById('content')
);
In my app.tsx I have:
export class App extends React.Component<any,{}>{
constructor(props){
super(props);
}
render(){
..
}
}
When I run the app I get this error:
ERROR in ./src/index.tsx
(24,12): error TS2339: Property 'test' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Component<{}, ComponentState>> & Readonly<{ childr...'.
How can I make sure this error is resolved or how can I pass in a property on my App component?