4 ms·
Interesting. Then why does everything look and behave so poorly? And if it's so easy, why doesn't React Native ship with at least every default native control w
by ryanwaggoner 9y ago
Interesting. Then why does everything look and behave so poorly? And if it's so easy, why doesn't React Native ship with at least every default native control wrapped?
Edit: what a beautiful example of what I'm talking about: https://github.com/facebook/react-native/issues/371 https://github.com/facebook/react-native/issues/371
- chourobin 9y agoI had many of your concerns early on but having just built an app in react-native, I think those concerns gradually went away. If you're a native developer, it should be relatively easy to get the app to look and feel great.
- chrisa 9y agoIn terms of poor performance: while it is possible to get good performance, the naive implementation of features might give you (accidentally) bad performance. For example: if you have a list of 1,000 things, you might put them in a scroll view first; but that will lead to very bad loading and scrolling performance (it will with straight native code as well). Instead, you should use FlatList (https://facebook.github.io/react-native/docs/flatlist.html https://facebook.github.io/react-native/docs/flatlist.html) which is built to be performant on long lists (by reusing components, etc). There are also a few additional considerations that you don't have when writing pure native code. One example is that if you send a lot of data (like a huge image) over the JavaScript bridge, then that can really slow down app performance. There are ways to get around that however, but it can be easy to accidentally do things like that which hurt performance (and those types of slowdowns might be confusing and difficult to track down). So yeah, it's not perfect - but it's the best cross platform development tool I've used, and most potential issues have workarounds (once you learn what's causing the issue).