Git Product home page Git Product logo

Comments (6)

gabn88 avatar gabn88 commented on July 17, 2024 2

@joantune How did you disable the offline behaviour? Do you have some code for the ErrorUrl?

from manifoldcordova.

 avatar commented on July 17, 2024

Thanks for reporting this. Unfortunately, we are not being able to reproduce that behavior in the latest published version of the plugin (v0.1.1 at the time of this writing).

Currently, we are showing the offline overlay in the following scenarios:

  • When cordova-plugin-network-information triggers the offline mode
  • When the Cordova webview fails navigating. In that case, we expect the following error codes:
    • 404
    • WebViewClient.ERROR_HOST_LOOKUP
    • WebViewClient.ERROR_CONNECT
    • WebViewClient.ERROR_TIMEOUT

It would be really helpful if you can identify the error code you are receiving from the webview when launching the application with no internet connection (you can check that by adding a breakpoint at this line in Android Studio).

from manifoldcordova.

joantune avatar joantune commented on July 17, 2024

Hi @msrodri .

We ended up disabling this feature, because it was disruptive to the user experience e.g. A user is on a webpage, there's no need to change that to an Offline message if he lost the connection, however, if he tries to do anything that needs internet access, he should get a proper error message.

And this behaviour can be attained with Cordova's ErrorUrl configuration.

Now, regarding the bug that I observed, I think that it might be related with the problem that we had when trying to switch to ErrorUrl: Basically, after debugging, we realised that our custom page wasn't being shown, because it wasn't properly whitelisted.

Hopefully Tuesday, when I pickup this project again, I will be able to do quick a test to sort this out. If I don't report back, you can close this, as it probably was related with the whitelisting (but i'll try to report).

However, and this might be a bit complicated, but as a feature request, I imagine that i'm not the only one wanting this kind of behaviour i.e. There are some apps where you don't want a user to be nagged with an offline message if he goes through a tunnel, others where it might make sense, although I'm not seeing that case now.

Another little thing that we collided against was this:

hostedwebapp.disableOfflinePage()

There should be a manifest option to do the equivalent, there might be one as I didn't search enough, but if there is, it should be in the docs IMO.

Anyway, great work for the tool, I think that it's pretty close of just running a command and instantly having your hosted webapp's mobile version shipped out. I would add some more info on the side effects of things settings like "display": "fullscreen", that basically in Android disrupt the status bar, which is not usual for Android apps (although I think that it might be in case of iOS ??).

As an effort to contribute, seen that we are rolling out the iOS and Android app, I'll keep posting the little or big things that I find lacking in appropriate issues.

Cheers

from manifoldcordova.

 avatar commented on July 17, 2024

This is great feedback. We'll close this issue for now and create a new one to review the offline experience.

from manifoldcordova.

roelbarreto avatar roelbarreto commented on July 17, 2024

I am interested also on disabling the offline behavior @joantune , can you post your solution? Thanks

from manifoldcordova.

burinov avatar burinov commented on July 17, 2024

I am also interested in solution.

from manifoldcordova.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.