Back to Blog Home
← all posts

NativeScript 7.1 - HMR Reenabled and Xcode 12.3 Support

December 30, 2020 — by Technical Steering Committee (TSC)

Updated @nativescript/webpack

4.0.0

HMR (Hot Module Replacement) is a feature that was introduced in NativeScript 5.3. With NativeScript 7 all @nativescript/webpack dependencies were updated to their latest versions, including copy-webpack-plugin which contained a significant change that interfered with HMR in NativeScript apps.

Many in the community have asked for a resolution and we are providing a major version bump prior to the Nativescript 8.0 release (scheduled for Q1 2021) so you can get HMR wroking again in the meantime. As previously announced, Nativescript 8.0 will bring webpack5 compatibility and improved HMR.

This is a major version bump as it does contain a version change to the copy-webpack-plugin which is requires changes in the webpack.config.js, thus considered a breaking change.

Upgrade instructions:

  1. Bump @nativescript/webpack to ~4.0.0
  2. Delete webpack.config.js (you can apply your customizations back in a moment)
  3. ns clean
  4. npm install (this will create a fresh webpack.config.js)
  5. If you had any customizations in the webpack config, you can now apply them to the new config.

Note: If you have many customizations in your webpack.config.js you can skip deleting your config, and manually update the CopyWebpackPlugin options based on this diff.

Updated @nativescript/core

7.1.0

This is a minor version update that contains several bug fixes as well as some improvements to iOS SafeArea handling, macro task scheduling to match the DOM event loop more closely.

See the CHANGELOG for more details!

Upgrade instructions:

  1. Bump @nativescript/core to ~7.1.0
  2. ns clean
  3. npm install
  4. Run your application as usual.

Updated @nativescript/types

7.1.0

This version contains all the latest typings for iOS 14.3. There were a ton of new api's! You can explore some of the new additions via Apple's documentation overview here as well as browsing the PR changeset including all the new api typings here.

Upgrade instructions:

  1. Bump @nativescript/types to ~7.1.0
  2. ns clean
  3. npm install
  4. Run your application as usual.

Updated @nativescript/ios and tns-ios

7.1.0 & 6.5.4

XCode 12.3 greeted us with another change that caused projects to stop building. A fix has been implemented in the runtimes!

We have released the fixes for all the runtimes:

Upgrade instructions:

  1. Bump the runtime you are using to the versions above
  2. ns clean
  3. npm install
  4. Run your application as usual.

Released @nativescript/template-blank-vue-ts

We have released an official Vue and TypeScript template @nativescript/template-blank-vue-ts!

The new template has been added to the CLI so you can easily create a new project with

ns create myVueApp --vue --ts

Updated CLI

7.1.0

We have released NativeScript CLI 7.1.0 with some nice features:

  • support for external source-maps in log parsing
  • support for the new Vue TypeScript template (ns create myVueApp --vue --ts)
  • a new ns fonts command to print required css to use a custom font - give it a try!
$ myCoolApp >>> ns fonts
┌────────────────────┬──────────────────────────────────────────────────────────────────────────┐
│ Font               │ CSS Properties                                                           │
│ fa-brands-400.ttf  │ font-family: "Font Awesome 5 Brands", "fa-brands-400"; font-weight: 400; │
│ fa-regular-400.ttf │ font-family: "Font Awesome 5 Free", "fa-regular-400"; font-weight: 400;  │
│ fa-solid-900.ttf   │ font-family: "Font Awesome 5 Free", "fa-solid-900"; font-weight: 400;    │
└────────────────────┴──────────────────────────────────────────────────────────────────────────┘

Thank you!

We hope everyone is enjoying the holidays!

The NativeScript team wishes you a happy New Year. See you in 2021!