This post is meant to be read in the context of its parent post "Lessons Learned on a React-Native Project". If you've stumbled on this particular page randomly, I'd recommend jumping over to that post and starting from there.
This was by far my favourite thing, which is pretty funny because the entire selling point of React-Native is fast feature development! It just doesn't mention all the ancillary stuff you'll probably need to pick up on the side!
Anyway, this was a breath of fresh air compared to the rest of the issues I'd been having. React-Native is really good at showing a consistent visual experience between the two platforms, so if this is essential to your project, I'd strongly recommend React-Native. Provided you can stomach the rest of the stuff that may come with it.
A big part of why feature development is so quick in React-Native comes down to the simplicity of the components, most of which roughly map to Web concerns (there's that familiarity again!). For example, the View
component maps to a div
in HTML land, and you'd use them similarly. When you actually look at the documentation for React-Native you can see there's only actually about 10 components you'll use regularly, most of which map to well-known concepts like Lists, Images, Buttons and Text.
One thing to be wary of is styling and layout, as I found it can be a bit brittle at times. To be fair, this isn't limited to React-Native, but anything that uses anything remotely like CSS. One thing in particular to watch out for in the context of React-Native is; if you introduce an enclosing View
tag for whatever reason (say, nesting some components inside a TouchableHighlight
as you're only allowed a single child element within this component), it's probable that styling for the component will break in ways you don't expect, as it won't always respect the outer container's style and things will vanish/move around. It's weird, but it could also come down to my lack of in-depth knowledge of CSS, Flexbox and the React-Native-flavour of these it uses.
Oh and Flexbox. Oh my god I love flexbox. It makes layouts fairly straightforward for the most part (and I'd suggest actually drawing it out if you're struggling to get things working). And if you combine that with Live Reload, you can iterate really quickly when styling up a new component. Heck yes. There's also a great resource I've used called Flexbox Froggy which is an adorable mini-game I'd highly recommend to get used to the quirks of Flexbox.
This is the main area that React-Native crushes the competition, especially when compared to Xamarin. I've found feature development (specifically styling/consistent looks between platforms) really painful in Xamarin. Styling and layout in XAML is horrible. Coming into React-Native for this particular area was a completely different world. Xamarin Forms 3 may change this opinion - as it's introduced a CSS-like syntax for styling - but I'll have to withhold judgement for the time being as I haven't had a chance to delve into it.
Next Section -> "The React-Native ecosystem varies wildly in quality and levels of support."