4 ms·
Ask HN: Should we build apps with React Native now?
- aaronbrethorst 9y agomaybe.
- roryisok 9y agogreat answer
- zn44 9y agodepends on what you want to build. In my experience it's great for simple prototypes. I see more and more people using it for bigger projects. Also you can always gradually move back to native if needed.
- swah 9y agoVery good point - maybe even if FB even showed that, more people would use RN and not even go back to native. So much FUD everywhere. The only FUD that doesn't exist is "try to make two apps in Java and Swift and fail"
- pattrn 9y agoI have had a production application live for almost a year that uses React Native. It has been a pleasure to work with, and I would recommend using it. So far zero crashes have been logged, no performance issues reported, and it has quite a few active daily users. Feel free to ask any questions! I'm happy to answer.
- swah 9y agoThanks! Here they go: 1) How much native code did you write? 2) Are you using native plugins? For what? 3) Are you being able to update RN versions? 4) Are you developing on a Mac / delivering on both platforms? I've been hesitating because simple stuff like Charts has little options for now. And because FUD.
- pattrn 9y ago1) I did not write any native code. 2) I use quite a few plugins containing native code. Older versions of react-native didn't handle this well, which required manually setting up linking for Android and iOS. This was painful. Thankfully, they added the "react-native link" command, which started doing this automatically. Since then, I haven't had any issues. 3) Upgrades from early version were also painful. I gave up the first time I tried, since the benefits didn't seem to outweigh the time it took to upgrade. Once they improved the upgrade process, I bit the bullet and upgraded. Since then, upgrades have worked flawlessly, so I've upgraded whenever they released features that replaced third-party libraries. 4) I develop on a Mac, and I release the application on both Android and iOS. Only one component differs between the two platforms: the header. I show a "Back" button on iOS, whereas I disable it on Android since it's unnecessary. Early on, I also found some discrepancies in styling. Text boxes, for instance, showed default fonts on Android, while they showed my custom fonts on iOS. They also included underlines, and tapping outside buttons with a visible keyboard required tapping twice. These turned out to be bugs, and I was able to hack around them pretty easily. I believe they have since been fixed. React Native definitely lacks a good charting solution, or at least it did when I wrote one. I haven't checked since then, since my custom solution solved my needs. It ended up working out well, since I was able to reuse my charting library to generate SVG-based charts for the web dashboard. If detailed charting is a requirement for an application, it will require some effort to get working on React Native, but it's not an insurmountable task. Overall, React Native definitely had some rough edges when I first released the app, but they have fixed all of the issues that annoyed me. It has improved significantly, and if I were to build another application, I would use it again.
- hkarthik 9y agoIf you have entrenched native mobile programmers, they will likely resist moving to React Native. It won't be worth the effort to convert an existing, large native iOS or Android (or both) app to React Native. However if you're just starting to move to mobile, React Native is the way to go. For new projects, its definitely worth a look if you don't have a strong dependency on the underlying native hardware.