enzymejs / enzyme-matchers

Jasmine/Jest assertions for enzyme
MIT License
892 stars 116 forks source link

jest-environment-enzyme index.d.ts should include global React #283

Open bschlenk opened 5 years ago

bschlenk commented 5 years ago

The included index.d.ts file should also include the global React instance. Without it, TypeScript complains that 'React' refers to a UMD global, but the current file is a module. Consider adding an import instead.. Then I have to manually import * as React from 'react'; to silence the error.

blainekasten commented 5 years ago

Would you be willing to submit a fix? I'm not much of a typescripter so i'm not sure what the solution is.

bschlenk commented 5 years ago

Yeah I’ll take a look at it when I have some time.