From a8a7f2a6923a9e642e50f5207483c4897c57b352 Mon Sep 17 00:00:00 2001 From: Qathom Date: Wed, 17 Jul 2019 19:28:36 +0200 Subject: [PATCH] Updated Riot example --- examples/phonon-and-riot/src/tags/app.riot | 39 +++++++++---------- examples/phonon-and-riot/src/tags/home.riot | 14 +++---- .../phonon-and-riot/src/tags/pagetwo.riot | 2 +- 3 files changed, 27 insertions(+), 28 deletions(-) diff --git a/examples/phonon-and-riot/src/tags/app.riot b/examples/phonon-and-riot/src/tags/app.riot index 613929db..8b98d7c2 100644 --- a/examples/phonon-and-riot/src/tags/app.riot +++ b/examples/phonon-and-riot/src/tags/app.riot @@ -13,29 +13,28 @@ PageTwo, }, onMounted() { - setTimeout(() => { - phonon.options({ - navigator: { - defaultPage: 'home', - animatePages: true, - enableBrowserBackButton: true, - templateRootDirectory: './tpl', - }, - i18n: null, // for this example, we do not use internationalization - }); - const app = phonon.navigator(); + phonon.options({ + navigator: { + defaultPage: 'home', + animatePages: true, + enableBrowserBackButton: true, + templateRootDirectory: './tpl', + }, + i18n: null, // for this example, we do not use internationalization + }); - app.on({ page: 'home', preventClose: false, content: null }); + const app = phonon.navigator(); - app.on({ - page: 'pagetwo', - preventClose: true, - content: null, - readyDelay: 1, - }); + app.on({ page: 'home', preventClose: false, content: null }); - app.start(); - }, 1000); + app.on({ + page: 'pagetwo', + preventClose: true, + content: null, + readyDelay: 1, + }); + + app.start(); }, }; diff --git a/examples/phonon-and-riot/src/tags/home.riot b/examples/phonon-and-riot/src/tags/home.riot index 73139606..561da884 100644 --- a/examples/phonon-and-riot/src/tags/home.riot +++ b/examples/phonon-and-riot/src/tags/home.riot @@ -7,13 +7,13 @@
diff --git a/examples/phonon-and-riot/src/tags/pagetwo.riot b/examples/phonon-and-riot/src/tags/pagetwo.riot index 36103ca5..ac3ced9b 100644 --- a/examples/phonon-and-riot/src/tags/pagetwo.riot +++ b/examples/phonon-and-riot/src/tags/pagetwo.riot @@ -20,7 +20,7 @@