Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error on android Webview #50

Open
falltodis opened this issue May 5, 2016 · 2 comments
Open

Error on android Webview #50

falltodis opened this issue May 5, 2016 · 2 comments

Comments

@falltodis
Copy link

DomReady worked before the webview on Android 4.4 ,But not work for Android 5+

@juliangruber
Copy link

what is the error you get?

@falltodis
Copy link
Author

I guess
if (typeof module != 'undefined') module.exports = definition() else if (typeof define == 'function' && typeof define.amd == 'object') define(definition) else this[name] = definition()
may make the problem , I can not get error detail and when I replace domready with a sample code bellow

function domready(fn) {
    var readyState = document.readyState;
    if (readyState === 'interactive' || readyState === 'complete') {
        fn(); 
    } else {
        window.addEventListener('DOMContentLoaded', fn); 
    }
};

It will work!
Android Webview after 4.4 is based on chromium , I searched for more infos but there is not related message

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants