NativeScript 1.1 bits are live and you can start using them immediately! If you are updating from 1.0 - please read the update instructions. With this release we delivered three new fundamental features for the NativeScript framework - support for npm modules, support for native iOS libraries and the initial version of NativeScript plugins. We also delivered a number of enhancements and bug fixes to the core framework - NativeScript is now more stable and faster.
As of today we are also starting a campaign to help local user groups to meet and talk about NativeScript. It is called “Summer of NativeScript” and if you are running a user group please make sure to reach out to us to see how we can help you out. More info on the campaign is available here. Please help us spread the word about NativeScript!
Before I go into more details here is a summary of what we are shipping today:
New Repeater UI component,
You can read the full release notes as part of our GitHub repo.
Let’s start with a little bit more info on the notable features we are shipping.
Please welcome the entire iOS native ecosystem in your NativeScript application!
With our 1.0 release we shipped support for native Android libraries and you are able to use any Android library in your NativeScript project. This is a huge deal because you can reuse the entire ecosystem of Android libraries in your NativeScript app. By utilizing them you get support for almost any mobile scenario out of the box.
Same is the case with iOS - there are tons of already implemented libraries for any mobile scenario you can imagine. Most of these libraries are distributed as pure static libraries or as frameworks or cocoapods. You can use all the Google SDKs, Facebook SDKs, twitter and thousands of libraries that offer rich UI visualizations or app helpers.
The image below shows the Google Maps static library running in a NativeScript iOS app.
You can see how this app works and how you can add the Google Maps SDK yourself at - https://github.com/NativeScript/sample-iOS-StaticLibs
Here is the actual code that deals with the Google Maps iOS SDK
To add an iOS library, you need to perform the following steps:
Open the Xcode project and add the library or the framework as a reference,
If you are adding a framework or a library that does not have resources, you don’t need to do anything else,
If the library has dependencies or resources, follow the steps that are specific to the static library to add it to the Xcode project,
Run the “prepare” command of the CLI,
With the next release you will be able to skip all these manual steps and add the library as a NativeScript plugin and the CLI tooling will perform the steps needed for the native project modifications. This leads us to the next fundamental feature that we are shipping today - the initial support for NativeScript plugins.
As an application developer, by using NativeScript plugins you will able to use cross-platform code that targets a specific scenario. As an author, by using plugins you will be able to distribute your code in a clean and organised way.
If you are interested to read more about the plugins, please read the documentation article where we describe the details of the architecture and the usage of plugins.
Speaking about plugins we can not miss to mention the great work done by the community so far. Please check the list of modules available today in this community driven repository. I will ask every module developer to convert their modules as plugins and to contact us so that we can list them as officially supported plugin for NativeScript.
and then in your page:
These are the most notable additions to NativeScript after our 1.0 release in May. If you have any feedback for us please write in the comments section below.