Closed
Description
Describe the bug
While trying to upgrade to the RC (anyone could link me the thread where we were discussing the RC, I can't find it anymore), I realised I missed some minors updates, and found breaking types between 11.5.0
and 11.5.1
.
node_modules/@testing-library/react-native/build/within.d.ts:48:152 - error TS2307: Cannot find module 'react-native/types' or its corresponding type declarations.
48 getAllByRole: import("./queries/makeQueries").GetAllByQuery<import("./matches").TextMatch, import("./queries/options").CommonQueryOptions & import("react-native/types").AccessibilityState & {
~~~~~~~~~~~~~~~~~~~~
...
18 node_modules/@testing-library/react-native/build/render.d.ts:51
18 node_modules/@testing-library/react-native/build/within.d.ts:32
All errors are regarding the way the import of AccessibilityState
is done as part of our build output.
Steps to Reproduce
Simply create a repo with RN@0.70 and a version of RNTL>=11.5.1, make sure to have skipLibCheck: false
in the compilerOptions
of your tsconfig and run typescript.
Versions
npmPackages:
@testing-library/react-native: 12.0.0-rc.0 => 12.0.0-rc.0
react: 18.1.0 => 18.1.0
react-native: 0.70.6 => 0.70.6
react-test-renderer: 18.1.0 => 18.1.0