Facebook javascript engine boosts react-native on android

The mobile app community received yet another boost when Facebook came out a few months ago to announce the launching of their new JavaScript Engine, Hermes. According to the company, the open-source engine is meant to boost the performance of android mobile apps built with JavaScript code. 

Facebook javascript engine

Nowadays, there is increasing complexity in the way JavaScript code mobile apps are designed as users’ needs continue to evolve. As a result, most tech giants often face the challenge of optimizing their solutions to meet the limited processing power and garage provided by many smartphones available today. That’s why there are so many lite versions of big JavaScript apps like Facebook, Uber, Twitter, Skype, and many others. 

But then, imagine a situation where JavaScript code engineers had the option to use a dedicated JavaScript engine optimized for building mobile applications by improving startup time and reducing download size. Of course, this would mean better performance for JavaScript apps. It is what Facebook has set to achieve with the new Hermes JavaScript code Engine. 

As expected, the Hermes JavaScript code engine is designed to react-native applications. However, for now, the engine is only utilized for JavaScript code applications on android devices. 

Facebook has already set things in motion by being the first to use it in most of their native android products, such as Oculus and Crisis Response. 

Main Features of the Hermes Engine

As earlier indicated, Hermes’s core functionalities are – reduced android APK download size, efficient memory usage, and reduced startup time. All of them lead to optimized performance and better development experience. Such experience is similar to the one provided by JavaScript quiz code applications and online casinos like novoline online.

The small memory usage of the JavaScript code engine is mainly due to the use of compact bytecode, which only gets loaded from the flash memory as needed. In the same manner, overhead is greatly reduced by allocating virtual address space in bits, as they are needed. It makes more memory to be available to the device operating system. 

It is also noteworthy to mention that the new JavaScript code engine supports modern JavaScript, popular known as ECMAScript 2015 or ES6. Compilation of the language is done at build time, which makes the device faster. 

Ultimately, the apps developed on Hermes will not only come out smaller but also better optimized for performance.

Just like React Native itself, the JavaScript code engine is open source. It makes it available for everyone and gives developers the option to tweak the JavaScript code examples to meet their needs.

Currently, Hermes doesn’t come with profiling tools for memory and time. However, there are plans by Facebook to include this feature in the future. We may also see a special debugging option available for Visual Studio Code JavaScript projects. 

Meanwhile, a JavaScript code checker may be used for this purpose until the company integrates the add-ons.

The Limitations of Hermes   

As earlier indicated, the new JavaScript code engine is designed to work with only mobile applications supported by React Native. It is a hybrid platform, which used to build apps to work on both Android and iOS. Other similar frameworks that support building apps with one code are Ionic and Flutter. 

Android and iOS

Although many big companies adopt react Native, there is still a lot of criticism about the framework. A good example is the need to integrate native code to utilize certain functionalities of the target device, such as sensors and cameras. 

Sometimes, this can be a challenge for developers, as they often have to connect the “dots” between React Native and native code, which might defeat the purpose of a single code base. It is exactly why Airbnb, who was once a big supporter of the JavaScript code framework, had to drop it last year. 

That said, apart from Facebook itself, there are still many big advocates of React Native. Some good examples are Walmart, Gyroscope, Bloomberg, and others.

It is important to note that the new JavaScript Code engine is mainly designed for building mobile applications. In addition, according to Facebook, there are no plans to make it a server-side technology for web apps or add it to run JavaScript code in web browsers. 

In other words, Hermes is not meant to replace Node JS or other JavaScript engines used in web browsers such as V8 engine or Spider Monkey. It is squarely targeted at the mobile environment building heavily upon javascript edit codes.

Apart from Hermes, other open-source projects have been recently released by Facebook are Pythia, for the machine learning community, Spectrum for easier and more efficient photo uploads, and a host of others. However, it seems the javascript code engine is the one making most of the headlines.

About the Author

Thomas Glare has over ten years’ experience as a tech writer. He mainly focuses on writing about the web and mobile development. When he is not writing, he is likely spending time with his family in London where he’s based.

Comments are closed.