Answer the question
In order to leave comments, you need to log in
Bug in TypeScript, how to fix?
Hey!
How to fix a bug
Type '{}' is not assignable to type 'Readonly<Props>'.
Property 'props' is missing in type '{}'
? interface Props {
props: Object;
}
class App extends React.Component<Props> {
constructor(props: Props) {
super(props);
}
public render() {
return (
<AppWrap>
<Block>Block</Block>
</AppWrap>
);
}
}
Answer the question
In order to leave comments, you need to log in
Remove this part
constructor(props: Props) {
super(props);
}
<App props={} />
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question