I'm building an open-source library of test utilities which also includes custom tech matches. But when creating test files and running them, a lot of errors are being raised regarding type definitions.
Refer to the following errors when running yarn test
The errors are related to two different type definitions, which are:
toBeVisibleis a custom Jest matcher that should come from@testing-library/jest-domtoHaveQueryParamis a custom Jest matcher created internally at my package and which I declared the definitions inside@types/jest.d.ts- This type definition should be loaded with declaration merging, but I presume it's not working due to the errors.
My question is: Why the type definitions aren't loading? I presume that there should be something wrong regarding the TS compiler or Jest configs