Turbo for React Native


I hope you are well.

I am trying to use React Native to replicate Turbo Native behavior, using Expo. The reason behind this is that I don’t have a Mac, and I also have iPhone. It makes it very difficult for me to test. With Expo, I can test on my iPhone and submit the app to the stores without a Mac, and it’s great. I also don’t quite understand how Turbo Android works. Thanks to Joe Masilotti’s tutorials I can somewhat understand Turbo iOS.

So far, I can slightly replicate the behavior. I’m using React Native Webview and React Navigation. Basically, when the URL changes, I intercept the new URL and do a new navigation. The problem is that when I go to a new screen, React re-renders the screen again, even though it’s the same screen in theory, and therefore I can’t reuse the Webview instance. It works, but it reloads everything from 0, including assets and javascript. It maintains the session correctly and that hasn’t been a problem at least.

Is there a better way to approach this?

If there is anyone interested in helping we could share code.