cypress-real-events icon indicating copy to clipboard operation
cypress-real-events copied to clipboard

Types are not working on Cypress 10 with TypeScript

Open nbouvrette opened this issue 2 years ago • 4 comments

I use e2e.ts with import 'cypress-real-events/support' and none of the IntelliSense functionalities work.

I noticed that your support.d.ts is also empty.

For example, you can check how cypress-wait-until built their type file as it works very well.

nbouvrette avatar Aug 05 '22 01:08 nbouvrette

Did you upgraded to the latest version? Please double check your installed version of plug-in.

dmtrKovalenko avatar Aug 05 '22 07:08 dmtrKovalenko

Yes all my packages are using the latest versions

nbouvrette avatar Aug 05 '22 11:08 nbouvrette

@nbouvrette , I had to add ///<reference types="cypress-real-events" /> to the top of support/index.d.ts in Cypress to get it to work. Hope that helps.

nerrante avatar Aug 18 '22 20:08 nerrante

Oh yeah this can be a workaround, but when the types are correctly included with the module, they should be available automatically when the package is imported.

nbouvrette avatar Aug 19 '22 05:08 nbouvrette