perfect-scrollbar icon indicating copy to clipboard operation
perfect-scrollbar copied to clipboard

Cannot use namespace 'PerfectScrollbar' as a type

Open throrin19 opened this issue 5 months ago • 0 comments

Hello, I try to migrate my project to full ESM but I have TS errors using PerfectScrollbar. It works fine before this.

I have several errors on using types part or class type in my code, one said namespace can't export Options, another you can't use namespace as type. But I can't find how to fix this :

image

This is TS errors for all parts :

  • PerfectScrollbar.Options : TS2694
  • ref<PerfectScrollbar>() : TS2709
  • new PerfectScrollbar() : TS2351

But normally the types availables with the package seems to be corrects. I don't understand the problem :/

throrin19 avatar Feb 01 '24 12:02 throrin19