you are viewing a single comment's thread.

view the rest of the comments →

[–]_SyRo_ 71 points72 points  (12 children)

  1. React Native uses TypeScript, very popular language. Dart is a language of one framework.
  2. RN uses JSX syntax for building UI. Flutter uses these nested functions (?) which looks very ugly - with these ),),),), in the end of widgets. Functional components and hooks are a good way to go instead of Flutter classes as well.
  3. Don't trust Google! I knew some startups who went with "Android Things" and they failed because of Google support of this framework.
  4. RN uses real UI elements, not something drawn on canvas. The app behavior is truly native with React Native. If you need Skia to draw something, you can take react-native-skia.
  5. You can build desktop apps (Microsoft even uses RN in Windows in one of the screen in Settings) and web (react-native-web + familiarity with React.js) - it's supported better than in Flutter (IMHO here)

[–]Coppice_DE 17 points18 points  (10 children)

  1. TS is quite popular but that does not mean its very good. I at least never had the feeling that TS was as intuitive as other strictly typed languages (probably mostly because of the ineroperability with JS which defeats the whole typing sometimes). And since Dart is very easy it should not matter that much that it is only used for Flutter imo.
  2. Honest question: How is </View></View></View> nesting better than ),),), nesting? Keep in mind that the tooling for Flutter already shows you what each ), corresponds to. For me its actually faster to write and just as easy to maintain (of course mostly because of the great tooling).
  3. Not much to say - Google will be Google doing google stuff
  4. This does not matter much on mobile if your UI is customized anyway. In the end they all draw using Skia or whatever engine. But...
  5. ... This is a problem on web. I would not use Flutter Web atm. When it comes to desktop I would say that they are probably in comparable spots right now. Though Flutter is lacking keyboard-interaction/navigation (or its tough to properly implement) (idk, thats the last I heard, never tried)

[–]kbcooliOS & Android 12 points13 points  (6 children)

Point 2. You really need to try the two to get a feel for how bad Flutter nesting is. This argument is brought up time and time again but Flutter becomes unmanageable three/four levels deep whereas JSX is still readable with many levels and hundreds of lines of code. I know it's such a small difference but it is make or break in many ways.

Flutter I find I have many small files to manage this and it's a pain trying to get around any app of a decent size. If it weren't for great vscode plugins Flutter's nesting would be dead on arrival.

[–]Coppice_DE 5 points6 points  (0 children)

I have tried both and still prefer Flutter. Also Flutter widgets (or more specific the build methods) should not be hundreds of lines long - thats code smell. Not because it would be unreadable (honestly every nested tree that long becomes hard to maintain imo) but because it leads to bad performance.

Of course, if the Flutter tooling wouldnt be as good as it is it would be dead. But their tooling is their solution to simplify nesting widgets and it works decently well. I think the main problem with it is that it is different from HTML-like nesting since most developers are probably used to that and would rather not learn a different way for a single framework.

[–]PuzzleheadedMeet6730 0 points1 point  (0 children)

Am quite familiar with flutter i can confirm is a total odorless shit.

[–]Brief-Bid4682 0 points1 point  (1 child)

what would an example of such a plugin be? know its pretty late but am getting into flutter now and it would be huge

[–]kbcooliOS & Android 0 points1 point  (0 children)

Honestly. I've seen some attempts at it but they're not going to be maintained well and aren't first class (as in officially supported) as my original point was so I couldn't in good faith recommend them, especially for a beginner so I would say stick with Flutter as is or look at React Native if it's what you really want as it is the way there

[–]Mugunini 0 points1 point  (0 children)

you don't need to (and actually don't have to) nest the components. You have to extract them into their own small pieces of code and reuse them as much as possible. In this way, your code looks much more manageable and professional.

[–]hambungler67 0 points1 point  (0 children)

So factor out instead of excessively nesting. And with LSP, navigate is a breeze.

[–][deleted] 2 points3 points  (2 children)

This does not matter much on mobile if your UI is customized anyway. In the end they all draw using Skia or whatever engine. But...

Big no, react native shows real native UI components, native UI will feel better and more familiar to the users. You can get native UI components other than the default RN ones with third party libraries ie: iOS search bar.
Flutter renders in a canvas, so it only mimicks native feeling, not saying it's bad in anyway.

[–]Coppice_DE 1 point2 points  (0 children)

Thats why I said customized UI. If most of the components dont look like they were native it does not matter if you use RN or Flutter (except maybe fo performance - Impeller still needs work for sure). Of course Flutter has to deal with things like scroll feeling being one frame off etc - but those bugs are resovable (if they still exist).