NativeScript v6.0.0 Release Notes
Release Date: 2019-06-28 // almost 5 years ago-
๐ Bug Fixes
- bundle: support for file qualifiers with webpack (#7386) (9fcc1dd)
- bundle: code-only typescript custom components with webpack (#7321) (9fcc1dd)
- bundle: component builder support for codeFile / cssFile / import with webpack (#7324) (9fcc1dd)
- bundle: different event order (NativeScript/nativescript-cli#4633) (8851835)
- โช restore TextField.textChange and Switch.checkedChange event syntax in xml (#7403) (76b5089)
- android: ignore gzip content-encoding for status code 204 (#7417) (4437cd6)
- android-transition: exit transition not executed after app suspend resume (#7402) (f08b491)
- css-state: _appliedSelectorsVersion assignment (#7405) (9ecf07f)
- observable-array: splice to notify correct amount of added items (#7426) (5e14de6)
- cancel contradictory gesture events (#7296) (b8a82f2)
- ๐ allow span descendants in FormattedString (#7369) (01c4b8c)
๐ Features
- bundle: bundle workflow support (#7320) (ecd9fc3)
- android: androidX support (#7039) (c5db112)
- BETA/EXPERIMENTAL: bottom navigation and tabs components (#6967) (0c2c1cc)
- โ add support for :focus pseudo class in TextField / TextView (#7396) (0bfddab)
- animation: support animating width/height properties (#5147) (e7c575)
๐ฅ BREAKING CHANGES
- ๐
AndroidApplication.currentContext
intns-core-modules/application
module is now removed.
๐ Use
AndroidApplication.startActivity
,AndroidApplication.foregroundActivity
, orAndroidApplication.context
properties instead.- ๐
start(...)
method intns-core-modules/application
module is now removed.
๐ Use
application.run(...)
method instead. Check the "Flexible Frame Composition" section in this document that explains the full migration path fromapplication.start(...)
toapplication.run(...)
and the implications from this change- ๐
loadPage(...)
method intns-core-modules/ui/builder
module is now removed.
๐ Use
createViewFromEntry(entry: NavigationEntry)
method intns-core-modules/ui/builder
module instead.- ๐
tns-core-modules/ui/core/dependency-observable
module is now removed.
๐ป Use
tns-core-modules/ui/core/properties
module instead.- ๐
ViewBase.showModal()
,ViewBase.showModal(moduleName: string, context: any, closeCallback: Function, fullscreen?: boolean, animated?: boolean, stretched?: boolean): ViewBase
, andViewBase.showModal(view: ViewBase, context: any, closeCallback: Function, fullscreen?: boolean, animated?: boolean, stretched?: boolean): ViewBase
method overloads are now removed.
๐ Use
ViewBase.showModal(moduleName: string, modalOptions: ShowModalOptions): ViewBase
orViewBase.showModal(view: ViewBase, modalOptions: ShowModalOptions): ViewBase
instead.- ๐
Frame.androidOptionSelectedEvent
andAndroidOptionEventData
interfrace intns-core-modules/ui/frame
module are now removed.
Event not raised by NativeScript core framework anymore.
- ๐
AndroidFrame.cachePagesOnNavigate
intns-core-modules/ui/frame
module is now removed.
Not used internally in NativeScript core framework anymore.
- ๐
stack()
method intns-core-modules/ui/frame
module is now removed.
๐ Use
getFrameById(...)
method if you want to retrieve a frame different than the topmost one instead.- ๐
AndroidActivityCallbacks.onCreate(activity: any, savedInstanceState: any, superFunc: Function)
method overload intns-core-modules/ui/frame
module is now removed.
๐ Use
AndroidActivityCallbacks.onCreate(activity: any, savedInstanceState: any, intent: any, superFunc: Function)
instead.- ๐
WebView.url
property intns-core-modules/ui/web-view
module is now removed.
๐ Use
WebView.src
property instead.- ๐
ios.getter(...)
function intns-core-modules/utils
module is now removed.
๐ Use the respective native property directly instead.
- ๐
View.observe(...)
method intns-core-modules/ui/core/view
module is now removed.
๐ Use
View.on(...)
method instead.- The addedCount variable from ObservableArray.splice(...) change event is always the amount of added items.
Migration steps: ๐ The old addedCount can be obtained by
const addedCount = event.addedCount - event.removed.length
- ๐ Fix to cancel contradictory gesture events (e.g. tap and double tap) introduces the following behavior breaking change
Before:
- iOS / Android:
- double tap: child tap -> parent tap -> child double tap -> parent double tap
- tap: child tap -> parent tap
After:
- iOS:
- double tap: child double tap
- tap: child tap
- Android:
- double tap: child double tap -> parent double tap
- tap: child tap -> parent tap
Migration steps: ๐ Move event handlers accordingly.