Notice: The Monaca & Onsen UI Community Forum is shutting down.
For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.
Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.
popPage does not send data in options
-
I am trying to make some kind of a select behavior by showing extra page with options and then upon selection, the page is popped and information about the selection is passed to the previous page.
The following line of code does not work as I expected:
document.querySelector('#myNavigator').popPage({data: {val: 'val from pop'}});
The hash from data is not available in the
navigator.topPage.data
Here is a codepen with the issue:
https://codepen.io/piotrm/pen/AXGGKVAm I missing anything obvious?
EDIT:
onsen2 rc17, vanilla JS
-
@Piotr-Mitoraj After checking it for a while… I just realized you are actually not using rc.17. It’s rc.14.
Update it to rc.17 and it will work ;)
-
oh, my bad! I updated only css definitions…Thanks a lot!
-
@Piotr-Mitoraj For the next time I’d recommend you to try things in our tutorial app and then export it to Codepen (there is a button to do it automatically). This way you will always use the latest version. And I think the interface is handy :)