I work on a project that uses React with Typescript. I am trying to import a package and the error I get when I run the file is that the package has no constructor.

I have noticed that error in many packages and I would like to ask if there is a way to make them work instead of trying to find another package that has a constructor.

The package that i am testing right now is called **jsPDF**

> 
> Uncaught TypeError: jspdf\_1.default is not a constructor
> 
> 
> 

My code is 

```
import jsPDF from 'jspdf';

export default class DataModelPage extends React.Component<any, any> {

public render(){
    let doc = new jsPDF()

    doc.text('Hello world!', 10, 10)
    doc.save('a4.pdf')

    return (
        <div>...</div>
    )
}

```