Skip to content

Commit ffec9c3

Browse files
committed
Make the new bindingContext parameter optional.
1 parent 3905086 commit ffec9c3

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

tns-core-modules/ui/page/page-common.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ export class Page extends ContentView implements dts.Page {
200200
};
201201
}
202202

203-
public onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext: any) {
203+
public onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext?: any) {
204204
this._navigationContext = context;
205205

206206
//https://github.com/NativeScript/NativeScript/issues/731

tns-core-modules/ui/page/page.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,9 +227,9 @@ declare module "ui/page" {
227227
* A method called before navigating to the page.
228228
* @param context - The data passed to the page through the NavigationEntry.context property.
229229
* @param isBackNavigation - True if the Page is being navigated from using the Frame.goBack() method, false otherwise.
230-
* @param bindingContext - An object to become the binding context of the page navigating to.
230+
* @param bindingContext - An object to become the binding context of the page navigating to. Optional.
231231
*/
232-
onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext: any): void;
232+
onNavigatingTo(context: any, isBackNavigation: boolean, bindingContext?: any): void;
233233

234234
/**
235235
* A method called after navigated to the page.

0 commit comments

Comments
 (0)