Major Additions in NativeScript 1.5
Esta pagina podría ser traducida de forma automática según su origen y preferencia del lector.
Para acceder al post original clic aquí
NativeScript 1.5 has been released, with major additions including TypeScript support and unit testing for NativeScript projects.
In the blog post Six major additions in NativeScript 1.5 release to skyrocket your developer experience, Valio Stoychev of Telerik says that the release “marks a major milestone” for NativeScript developers.
One of the biggest developments in the 1.5 release is the support for TypeScript, allowing NativeScript users to develop their projects in TypeScript, without the need for TypeScript compilers. Stocyhev says:
Building and running your app with the CLI commands will automatically compile the TS files and deploy the output on the device. All of this is happens transparently for you, so all you need to do is write your TS code.
Also improved in 1.5 is NativeScript’s refactored LiveSync. The challenge to make LiveSync both smarter and faster began in October with contributor Todor Todev and the issue Smarter LiveSync #1007 that aimed to:
- Be smarter about the changes that are being made to the files and do the following for:
- CSS – just update the file and reload dynamically the new CSS in the live tree of visual objects. This requires changes in the common platform modules.
- XML – compute a change diff gram and apply the change to the live visual tree.
The framework’s hot reload functionality now immediately applies changes made to XML or CSS files on the running app.
Also new in 1.5 is the introduction of a way for users to unit test their NativeScript projects. Contributor Stefan Dragnev raised the issue with the idea that users would be able to “write tests on their dev machine and execute them on a device or emulator with no friction” and “be able to use a testing framework they’re familiar with.”
NativeScript’s unit test runner is based on Karma, Google’s open source testing tool, with adapters for popular frameworks like Jasmine, QUnit and Mocha.