Answer the question
In order to leave comments, you need to log in
I got the error does not have any construct or call signatures how to solve it?
Hello !
The situation is as follows .... there is a component No. 1 (class) from it we call component No. 2 (class) wrapped in compose .
If component #1 is in a file with the jsx extension, then everything is fine, there are no errors. But if the call to component No. 2 comes from component No. 1, which is located in a file with the tsx extension, then the error
does not have any construct or call signatures occurs.
question ... what needs to be done to get rid of it.
component #2
import React from "react"
import { connect } from "react-redux"
import { withRouter } from "react-router"
import { compose } from "redux"
import { ArticleDataType } from "../../../redux/company"
import { AppStateType } from "../../../redux/reducer_store"
import { getCompanyArticlesSelector } from "../../../redux/Selectors"
type ArticleContainerType={
article:Array<ArticleDataType>
}
class ArticleContainer extends React.Component<ArticleContainerType>{
render(){
return(
<div> ArticleContainer </div>
)
}
}
let mapStatetoProps = (state:AppStateType)=>({
article:getCompanyArticlesSelector(state)
})
export default compose(connect(mapStatetoProps,{}),withRouter)(ArticleContainer)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question