0

I've read some posts (github, stackoverflow, etc.) about this kind of issue, but I don't really get the right solution.

I'm creating a Cordova app* and I'm testing it on an Android 4.3 and I've some issue with the dropdown ( html tag). When I touch the select the option list open and close instantly.

The problem seems to come from fastclick.js cause when I remove it, it works ok but it looks not really good (as you know).

What could you advice me to do to fix it ?

Big thanks.


Code Sample :

onDeviceReady: function() {             
    // Fixing the Status Bar Issue on iOS7
    StatusBar.overlaysWebView( false );
    StatusBar.backgroundColorByHexString('#ffffff');
    StatusBar.styleDefault();

    // Avoiding the 300ms Click Delay
    //FastClick.attach(document.body);
    [...]
}

App details :

  • Base on the Apache Cordova Tutorial
  • Ratchet Components
  • Replace content with jQuery
EricDamp
  • 11
  • 2
  • Have you added debugger; tags and stepped through your code? I also ran into some issues when coding my one hybrid app. Use Chrome, open dev console (F12) then step through the code and the answer to what is failing/not running will be revealed. – Dan Tromp Jan 14 '16 at 11:27
  • Hi Daniel, I don't have debugger on the mobile device but on Chrome there is no error. Do you think another JS error (somewhere) could make it happen ? – EricDamp Jan 14 '16 at 12:09
  • Hmm it could very well be.. Hard to say without the code – Dan Tromp Jan 14 '16 at 12:11
  • Also, there is no issue in Chrome, only on the mobile device. – EricDamp Jan 14 '16 at 12:15
  • You use chrome to debug a web app on your mobile device - then you can pick up what the errors are etc. – Dan Tromp Jan 14 '16 at 12:26
  • Yep, that's how I do. I've no JS error anywere with Chrome...pretty weird... – EricDamp Jan 14 '16 at 14:39

1 Answers1

1

I can confirm, it was due to Fastclick. I added the needsclick class on my SELECT tags and it fixed the issue.

Thanks for your time.

E.

EricDamp
  • 11
  • 2