talknagish / react-native-turbo-starter

React 0.68+ Turbo Module starter using codegen with typescript for Objective-C and Java/Kotlin with C++ shared library. 🚀🚀🚀
MIT License
381 stars 27 forks source link

Use `getEnforcing` instead of unsafe `get` cast #11

Closed mrousavy closed 2 years ago

mrousavy commented 2 years ago

get + a force-cast is not safe. Instead, use getEnforcing, the type-safe method that will throw an error if it's not found.

alon7 commented 2 years ago

Thanks for the contribution!