Safari on Windows and iOS App doesnt select initial Tab
-
When I open my app on a Safari on Windows or in my iOS App my Meteor App with the React-OnsenUI Framework doesnt select an initial Tab.
If I open it on Chrome, Firefox or on a Safari in a Mac! It works as expected.
The demo
https://onsenui.github.io/react-onsenui-kitchensink/
tested on Safari on Windows
works too. Havent compiled it on an iOS App yet.
Im running against a wall for days with this issue since im almost using the same code as the demo
Demo Tab Code
https://github.com/OnsenUI/react-onsenui-kitchensink/blob/master/main.jsMy Code
https://gist.github.com/JWPapi/2af216e6e1d696e988c07c75900fd7bb
-
solved. Will post solution later.
-
It was due a error in my componentDidMount() that tried to register a gcm messaging service. I got a notification in the safari console, didnt thought it would hinder the whole app in something. So probably a takeaway for me is to fix all console errors first :)
-
Hi!
@Julian-Wagner I also run the demo example but it doesn’t show the initial tab active at all! How can you make the first tab active when first going to the tab page?
-
@iriekun As demonstrated in the help documents, this section sets the initial state:
getInitialState: function() { return { index: 0 } }
The tabs are basically a 0 based array. Change the number to indicate the tab.