You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And the reason that these errors occur is because index.d.ts is importing .ts[x] files instead of definition files which causes the compiler to include them during compilation.
Additional links and references
No response
The text was updated successfully, but these errors were encountered:
mattijsf
added a commit
to mattijsf/rnmapbox-maps
that referenced
this issue
Jan 6, 2023
Mapbox Implementation
Mapbox
Mapbox Version
default
Platform
iOS, Android
@rnmapbox/maps
version10.0.0-beta.62
Standalone component to reproduce
Not relevant. See Steps to reproduce.
Observed behavior and steps to reproduce
npx react-native init MapboxV10TS --template react-native-template-typescript
cd MapboxV10TS
yarn add @rnmapbox/maps@10.0.0-beta.62
open App.tsx
import MapboxGL from "@rnmapbox/maps";
npx tsc --noEmit
(observe that there are no errors)open tsconfig.json
"noUncheckedIndexedAccess": true
tocompilerOptions
npx tsc --noEmit
:Expected behavior
Changes to project local typescript configuration should not impact files imported from
node_modules
Notes / preliminary analysis
Some might say to use
skipLibCheck: true
or to add anexclude
section tocompilerOptions
. This will not work since due to:https://github.com/Microsoft/TypeScript/wiki/FAQ#why-is-a-file-in-the-exclude-list-still-picked-up-by-the-compiler
And the reason that these errors occur is because index.d.ts is importing .ts[x] files instead of definition files which causes the compiler to include them during compilation.
Additional links and references
No response
The text was updated successfully, but these errors were encountered: