3 ms·
Cordova is the "electron" equivalent for mobile. I.E. running a browser rendering engine embedded inside an app. There are 2 main reasons for making (or using)
by Illniyar 8y ago
Cordova is the "electron" equivalent for mobile. I.E. running a browser rendering engine embedded inside an app.
There are 2 main reasons for making (or using) the *-native libraries as opposed to using a browser rendering approach -
1- performance. Html and CSS are insanely bloated specification for making an app. There is really no way for a browser to rival the performance of a native app. This comes into play in mobile more then desktop and is really visible when dealing with animations and very large lists/tables.
2- native looking UI. using electron you can fake a webapp to look like a native app, but it will never have all of the edge cases (for example some keyboards don't open in a browser. Web inputs behave differently then native inputs. And of-course animations).
You can think of the Native part in react-native or native-script etc... as native ui components. Which is what all of these technologies are attempting to achieve - having the look and feel of the native components of each OS while keeping the logic and layout code the same.
As to why vue-native, react-native, nativescript (angular) etc... rather then having a single base where you can use multiple different frameworks on top - nativescript is trying to do that. react-native is built in such a way that only virtual dom diffing based frameworks can work with it (which is why vue can while angular can't)