我是typescript的大一新生。我不明白我的代码中的这个错误。

我用IProps来描述类的props。为什么typescript会检查这个类的方法?我怎么解决这个问题?
export interface IProps extends FormComponentProps {
dispatch: Dispatch<any>;
loading: any;
}
@Form.create()
@connect(({ global, loading }) => ({ global, loading }))
export default class MessageBoard extends PureComponent<IProps> {
state = {
activated: false,
};
deactivate = () => {
this.setState({ activated: true });
};
...
render() {
...
return (...);
}
}