In 2016 the answer was " interpreted " based on this question Does React Native compile JavaScript into Java for Android?. However, since 2022 React Native has introduced new architecture:
The New Architecture dropped the concept of The Bridge in favor of another communication mechanism: the JavaScript Interface (JSI). The JSI is an interface that allows a JavaScript object to hold a reference to a C++ and vice-versa. Once an object has a reference to the other one, it can directly invoke methods on it. So, for example, a C++ object can now ask a JavaScript object to execute a method in the JavaScript world and viceversa.
https://reactnative.dev/docs/the-new-architecture/why
To my understanding, it's still an interpreted approach. But some articles and one master's thesis I read today claim that it's compilation-based without clear explanation of the statement. Perhaps my understanding is wrong. So is React Native still interpreted or now it's compiled?
React Native still includes Javascript code which is executed in a JS interpreter, which one specifically will be open thanks to the changes of the new architecture.
Here's a neat article which compares the old and new architectures in sufficient detail: https://medium.com/coox-tech/deep-dive-into-react-natives-new-architecture-fb67ae615ccd
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With