React Native vs.Flutter:2020年待决决定

React Native and Flutter are the top mobile frameworks for building iOS and Android mobile applications. These frameworks have been the gossip amongst the developer community, with a lot of competition and comparison between the two in recent years.

React Native和Flutter是用于构建iOS和Android移动应用程序的顶级移动框架。 这些框架一直是开发人员社区中的闲话,近年来,两者之间存在很多竞争和比较。

本机移动应用程序开发的问题 (The Problem With Native Mobile App Development)

Android Studio and Xcode have been dominating the mobile development industry until certain problems were raised. Thus, requiring an optimized solution. The problems were:

在出现某些问题之前,Android Studio和Xcode一直主导着移动开发行业。 因此,需要优化的解决方案。 问题是:

  • The need for different codebases for different platforms (iOS and Android)

    不同平台(iOS和Android)需要不同的代码库
  • Hiring platform-specific developers was expensive

    雇用特定于平台的开发人员非常昂贵
  • Development and maintenance costs were high

    开发和维护成本很高

This resulted in the introduction of cross-platform mobile development frameworks such as React Native and Flutter, which would help in developing mobile apps for different platforms including Android and iOS, with a single codebase exclusively.

这导致引入了跨平台的移动开发框架,例如React Native和Flutter,这将有助于通过单一代码库为包括Android和iOS在内的不同平台开发移动应用程序。

跨平台移动应用开发 (Cross-Platform Mobile App Development)

By considering cross-platform mobile development frameworks, businesses and organizations have been able to target a broader audience, effectively, and at a lower cost. These outcomes manifested a positive impact on the popularity of both, React Native and Flutter, in the industry.

通过考虑跨平台的移动开发框架,企业和组织已经能够以较低的成本有效地瞄准更广泛的受众。 这些结果表明,它对业界的React Native和Flutter的普及都产生了积极影响。

Even though there is a surplus of other available frameworks, React Native and Flutter have been leading in popularity with a win-win for both the business and its clients, resulting in new trends, and it has been the most discussed amongst the software development community.

即使有很多其他可用的框架,React Native和Flutter仍在业务和客户双赢方面领先于流行,从而产生了新的趋势,并且在软件开发社区中讨论最多。 。

React本机 (React Native)

React Native was introduced by Facebook in 2015, which was later discovered by a larger community of developers and then became community-driven. React Native is an open-source mobile application framework, which uses React with native platform capabilities to develop applications for Android, iOS, Web, and UWP.

React Native是Facebook在2015年推出的,后来被较大的开发人员社区发现,然后由社区驱动。 React Native是一个开放源代码的移动应用程序框架,它使用具有本地平台功能的React来开发适用于Android,iOS,Web和UWP的应用程序。

Some apps that make use of React Native are: Facebook, Instagram, Tesla, Uber Eats, Discord, Wix, Walmart, etc.

一些使用React Native的应用程序是:Facebook,Instagram,Tesla,Uber Eats,Discord,Wix,沃尔玛

(Flutter)

Flutter was introduced by Google in May 2017. But, its most stable release was in December 2018. It is an open-source UI software development kit used to develop applications for Android, iOS, Linux, Mac, Windows, Google Fuchsia, and the web.

Flutter由Google在2017年5月推出。但是,最稳定的版本是在2018年12月。它是一个开源UI软件开发套件,用于开发Android,iOS,Linux,Mac,Windows,Google Fuchsia和网络。

Some apps made using Flutter are:Google Ads, Alibaba.com, Realtor.com, etc.

使用Flutter制作的一些应用包括:Google Ads,Alibaba.com,Realtor.com

终极比较 (The Ultimate Comparison)

With both Flutter and React-Native being the hot topic in recent days and the competitive debate amongst the development community, many developers are in the bubble of uncertainty in determining which framework to choose to learn to build mobile apps.

随着近来Flutter和React-Native成为热门话题以及开发社区之间的激烈争论,许多开发人员在确定选择哪种框架来学习构建移动应用程序时遇到了不确定性。

Therefore, here is a distinct comparison to highlight the odds and evens of both frameworks under the criteria mentioned below.

因此,这是一个明显的比较,以突出显示在以下提到的标准下这两个框架的几率。

Google趋势 (Google Trends)

Image for post
Image Source: https://trends.google.com/trends/explore?cat=5&date=today%205-y&q=React%20Native,Flutter
图片来源: https : //trends.google.com/trends/explore?cat=5&date=today%205-y&q=React%20Native,Flutter

On Google Trends, over the last five years, Flutter has overtaken React Native. But, this does not determine that Flutter is a better option than React Native. We need to understand the rationalizing behind the trends.

在过去的五年中,在Google趋势上,Flutter超过了React Native。 但是,这并不意味着Flutter比React Native更好。 我们需要了解趋势背后的合理化。

Flutter was introduced very recently, therefore, many developers and programming enthusiasts are driven by curiosity and interest in learning this new framework. However, in the industry, React Native is still used by developers as it is more stable, and it has a higher adoption rate compared to Flutter.

Flutter是在最近才引入的,因此,许多好奇心和对学习这个新框架的兴趣驱使开发人员和编程爱好者。 但是,在业界,由于其更稳定,并且与Flutter相比,它的使用率更高,因此开发人员仍在使用React Native。

编程语言 (Programming Languages)

Flutter uses a language called Dart. Dart is built with the best and optimized ideas from different programming languages. It is a language that has a syntax which is similar to Java and Javascript. A simple example of code in Dart would be:

Flutter使用一种称为Dart的语言 Dart使用来自不同编程语言的最佳,最优化的构想来构建。 它是一种语法类似于Java和Javascript的语言。 Dart中的简单代码示例为:

// dart - hello worldvoid main() {
print('Hello, World!');
}

You can access the official documents for Dart here and the official documentation for Flutter here.

您可以访问Dart正式文件在这里和颤振的官方文档在这里

React Native uses Javascript. React Native is built on top of React, which is built on Javascript. Therefore, if you have to learn React Native, you will require prior knowledge of Javascript. You can access the complete React Native official documentation here.

React Native使用Javascript。 React Native建立在基于Javascript的React之上。 因此,如果您必须学习React Native,则需要具备Javascript的先验知识。 您可以在此处访问完整的React Native官方文档。

Javascript has been around the software development community for a very long time and there are plenty of resources to learn javascript from. A simple example of code in javascript would be:

Javascript已经存在于软件开发社区很长时间了,并且有很多资源可以学习Javascript。 javascript中的代码简单示例为:

// javascript -  hello worldalert( 'Hello, world!' );

The documentation for Javascript can be found everywhere on the internet and you can access a simple reference to one here.

Javascript的文档可以在Internet上随处找到,您可以在此处访问对它的简单引用。

社区 (Communities)

Flutter and Dart have been introduced to the developer community recently, and comparatively, it has a smaller community of developers. Google has spent a lot on developing Dart and the community is continuing to grow.

Flutter和Dart最近已引入开发人员社区,相对而言,它的开发人员社区较小。 Google在开发Dart上花了很多钱,并且社区还在不断发展。

Flutter has communities on StackOverflow, Slack, and many other platforms. You can find more about the Flutter community here.

Flutter在StackOverflow,Slack和许多其他平台上都有社区。 您可以在此处找到有关Flutter社区的更多信息。

React Native has a larger community of developers than Flutter, contributing towards its development. The Javascript community is even larger than the React Native community as it has been co-existing for a very long time and assistance can be found almost anywhere around the internet. This certainly explains why React Native has a higher adoption rate in comparison to Flutter.

React Native比Flutter具有更大的开发者社区,为它的发展做出了贡献。 Java社区比React Native社区更大,因为它已经很长一段时间共存,并且可以在Internet的几乎任何地方找到帮助。 这无疑可以解释为什么与Flutter相比,React Native的采用率更高。

Furthermore, support for React, React Native, and Javascript on the internet is more accessible. There are millions of lines of code that are freely available on the internet and can be simply “lifted off” and used in your projects.

此外,更易于访问Internet上对React,React Native和Javascript的支持。 互联网上免费提供了数百万行代码,可以将其“提升”并在您的项目中使用。

The React Native community page, on their official website, state the other platforms that accommodate their communities, such as StackOverflow, and Medium. You can find more about the React Native community here.

在其官方网站上的React Native社区页面上,说明了容纳其社区的其他平台,例如StackOverflow和Medium。 您可以在此处找到有关React Native社区的更多信息。

UI小部件 (UI Widgets)

The best thing about Dart is that it comes with a comprehensive set of UI widgets, which can be lifted right out of the box and used, whereas it is not the same with React Native. The catalog of widgets for Flutter can be found here.

关于Dart的最好的事情是,它带有一组全面的UI窗口小部件,可以立即将其提起并使用,而React Native则不同。 Flutter的小部件目录可以在这里找到。

In react native, the set of UI widgets is minimal, and therefore, software developers and programmers have to reach out for third party libraries for UI widgets and may sometimes have to make their custom UI widgets. The collection of UI widgets that come with react-native can be found here.

在react native中,UI窗口小部件的集很少,因此,软件开发人员和程序员必须向UI窗口小部件的第三方库寻求帮助,有时可能需要制作其自定义UI窗口小部件。 可在此处找到带有react-native的UI小部件的集合。

工作机会 (Job Opportunities)

As of August 2020, on Indeed, React Native has roughly around 2,320 job openings and Flutter has an approximate of 232 job openings. These values are my own research and may change with time.

截至2020年8月,确实,React Native大约有2320个职位空缺,Flutter大约有232个职位空缺。 这些值是我自己的研究,可能会随着时间而改变。

The job market seems to be favoring React Native. This is due to the strong establishment of React Native over a longer period in the software industry, and it is comparatively more stable and has a higher adoption rate.

就业市场似乎偏爱React Native。 这是由于React Native在软件行业中建立了很长的一段时间,并且相对更稳定并且采用率更高。

The variation in trends in between the job openings and google trends, of Flutter and React Native, seems to be contradicting. This is because, as previously discussed, the programming enthusiasts are curious to learn this new and trending framework, although the industry seems to be keen on wanting more React Native developers than Flutter developers.

Flutter和React Native的职位空缺和google趋势之间的趋势差异似乎是矛盾的。 如前所述,这是因为,尽管业界似乎渴望与React开发人员比Flutter开发人员更多,但编程爱好者对学习这种新的趋势框架感到好奇。

However, numbers may differ from one job-search platform to another. So, do your own research too, as this would give you more accurate and precise figures, at your point in time. You can refer to any website you prefer when researching the job market on your own, whether it be LinkedIn or any other.

但是,人数可能从一个求职平台到另一个求职平台有所不同。 因此,也要进行自己的研究,因为这样可以在您的时间点上为您提供更准确的数据。 当您自己研究就业市场时,可以参考喜欢的任何网站,无论是LinkedIn还是其他网站。

我应该学习哪一个? (Which One Should I Learn?)

If you are wondering which framework to learn, there are certain questions you need to ask yourself. Learning is a time-consuming process, as you will have to continue to master your coding skills and familiarize yourself with the framework, once you have decided to proceed.

如果您想学习哪种框架,则需要问自己一些问题。 学习是一个耗时的过程,因为一旦决定继续学习,您将必须继续掌握您的编码技能并熟悉该框架。

Ask yourself this question: “Why should I learn Flutter/React Native?”

问自己一个问题:“我为什么要学习Flutter / React Native?”

This would raise a couple of questions and answers that would direct you to identify your goals, which will then determine the factors you must consider when making your decision. The two obvious conclusions would narrow down to:

这将引发一些问题和答案,这些问题和答案将指导您确定目标,然后确定您做出决定时必须考虑的因素。 这两个明显的结论将缩小为:

找工作 (Get a Job)

If your ultimate goal is to get a job, then the job market is what you must consider researching. As mentioned above, the job market for React Native is comparatively larger in number to the demand for Flutter.

如果您的最终目标是找到一份工作,那么就必须考虑研究就业市场。 如上所述,React Native的就业市场在数量上相对于Flutter的需求更大。

However, do not settle down with the figures that I have stated above. Instead, carry out your research too as this would lead you to different ideas and help you with narrowing down your options when making your decision.

但是,不要对我上面所说的数字感到满意。 相反,也要进行研究,因为这会使您产生不同的想法,并帮助您在做出决定时缩小选择范围。

Do not make decisions based on what people say. A lot of people have different opinions and may be biased. Therefore, make decisions based on the data off your research.

不要根据人们的意见做出决定。 很多人有不同的意见,可能会有偏见。 因此,请根据研究数据做出决策。

建立一个应用程序 (Build an App)

If your goal is to build an app, the job market is not what you should be acknowledging. What should matter to you is to build the app, and sell it!

如果您的目标是构建应用程序,那么就业市场就不是您应该承认的。 对您来说重要的是构建应用程序并将其出售!

If you have prior experience with Javascript and React, you can consider React Native, as it is based on React and everything about React applies on React Native, but with a few more additional capabilities for native mobile development.

如果您以前有Javascript和React的经验,则可以考虑使用React Native, 因为它是基于React的,而关于React的所有内容都适用于React Native,但还有一些其他的用于本机移动开发的附加功能。

Also, Flutter is yet an open option. If you want to learn Flutter, the path is relatively quite simple, as you will first have to learn Dart, and then Flutter itself. It is faster than covering the learning path of Javascript, React JS, and then learning React Native.

而且,Flutter仍然是一个开放的选择。 如果您想学习Flutter,则路径相对简单,因为您首先必须学习Dart,然后才是Flutter本身。 它比介绍Javascript,React JS和学习React Native的学习路径要快。

结论 (Conclusion)

Trends are bound to change. Therefore, don’t let alone trends to influence your decision making. Perform in-depth analysis and identify your ultimate goals, and this would help you sharpen your thinking and narrow down your options in making your decision. Don’t make a permanent decision for your temporary emotion.

趋势注定会发生变化。 因此,别说趋势会影响您的决策。 进行深入分析并确定最终目标,这将有助于您加深思考并缩小决策范围。 不要为您的暂时情绪做出永久性决定。

I have provided an unbiased comparison on both the frameworks based on facts of my personal research. So, decide based on your own researched data. Not what others say. I hope this article has helped you understand and make your decision on what framework to choose to learn, to build your next project for 2020. Have fun and enjoy coding.

我根据个人研究的事实对这两个框架进行了公正的比较。 因此,请根据您自己的研究数据进行决策。 不是别人说的。 我希望本文能帮助您了解并决定选择哪种框架学习,以构建2020年的下一个项目。玩得开心,享受编程。

翻译自: https://medium.com/better-programming/react-native-vs-flutter-a-decision-pending-in-2020-65bf5835c8ed

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值