Digging through the api it just looks much more capable in directly calling android instead of abstracted cross platform blobs.
Digging through the api it just looks much more capable in directly calling android instead of abstracted cross platform blobs.
I first tried the Angular version before the final version of Angular was released and I recall occasions where the documentation for NativeScript was behind the actual API. I had to look at the actual code samples to figure out the correct APIs.
The next time I looked at it, I tried the regular JavaScript version and I recall having trouble deciphering the API for the SideBar plugin.
This left me feeling a bit insecure about the product. It looks to have a lot of potential though but it could use a bit more polish and better documentation.
var button = new Button(...);
// Set the common properties:
button.backgroundColor = ...;
button.text = ...;
if (iOS) {
// Set iOS-specific properties
} else { // Set Android-specific properties
}The variable is app.ios / app.android
So that, for instance, you can be sure exactly when the resources for an image have been deallocated.
Perhaps I'm misunderstanding your concern, but it doesn't look like js allocates for the actual object just a proxy for the java.
This is exactly what React Native does too. The difference is how much of this is done. NativeScript encourages you to stay on the JS side of the bridge- that's why they surfaced those API's. React Native encourages you to cross the bridge to do heavy lifting and then bring the final answer back. This means you typically end up utilizing the bridge a lot more for similar features in NativeScript than you would for React Native. Of course, you pay for this in React Native by having to write Native modules. (I'm purposefully ignoring some of the work I've seen in the RN community to surface these API's in the same way that NativeScript does).
At the bottom of that article there are suggestions on how to mitigate some of these problems, and just about all of them relate to minimizing unnecessary trips across the bridge.