mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
chore: working with builder xml require vs dynamic import wip
This commit is contained in:
@@ -203,11 +203,13 @@ export function waitUntilNavigatedFrom(action: Function, topFrame?: Frame) {
|
||||
const currentPage = topFrame ? topFrame.currentPage : Frame.topmost().currentPage;
|
||||
let completed = false;
|
||||
function navigatedFrom(args) {
|
||||
console.log('navigatedFrom called');
|
||||
args.object.page.off('navigatedFrom', navigatedFrom);
|
||||
completed = true;
|
||||
}
|
||||
|
||||
currentPage.on('navigatedFrom', navigatedFrom);
|
||||
console.log('calling action!');
|
||||
action();
|
||||
TKUnit.waitUntilReady(() => completed);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user