Cordova-plugin-ionic-webview: How to validate correct configuration and where to find all available preferences?

Created on 18 Jan 2019  路  2Comments  路  Source: ionic-team/cordova-plugin-ionic-webview

We just upgraded to this module and WOW, it's much faster! Solid work, Ionic team!

A few questions:

  1. When installing cordova-plugin-ionic-webview, do we need to add anything to the config.xml? Seems like I just installed and it鈥檚 already working without changing config.xml other than the dependency injection
  2. Where are all of the preferences that we can set for both iOS and Android for these web views?
  3. How can I verify that the engine is, indeed, installed? Would be great to be able to validate its version, etc. within a given application
  4. What are some ways to test the overall performance improvement of this engine versus the default one in Cordova by A/B testing current application? For example, memory footprint, performance, etc.

Thank you!

Most helpful comment

If you want default settings then you don't need to add anything to the config.xml, if you want to change them, here you can see the available preferences https://github.com/ionic-team/cordova-plugin-ionic-webview#configuration
If you miss any or the ones present are not clear, create an issue and I'll try my best do document it.
To verify that it's working, if in a desktop Safari you inspect the iOS app, you'll see that it's served from ionic:// scheme instead of using http or file. For Android inspect from desktop Chrome and you'll see that it's served from http://localhost instead of file.

About the performance testing we don't have anything in place, Xcode allows to check memory and some other things, but you'll have to do it yourself for your own app.

All 2 comments

If you want default settings then you don't need to add anything to the config.xml, if you want to change them, here you can see the available preferences https://github.com/ionic-team/cordova-plugin-ionic-webview#configuration
If you miss any or the ones present are not clear, create an issue and I'll try my best do document it.
To verify that it's working, if in a desktop Safari you inspect the iOS app, you'll see that it's served from ionic:// scheme instead of using http or file. For Android inspect from desktop Chrome and you'll see that it's served from http://localhost instead of file.

About the performance testing we don't have anything in place, Xcode allows to check memory and some other things, but you'll have to do it yourself for your own app.

Thanks for the quick response, @jcesarmobile! That's pretty awesome how seamless you all have made the installation process.

1) So I, presume, that simply having the dependency installed, the engine takes over?
2) Regarding the preferences, I did see that link but it's not an exhaustive list of various preferences. For example, when I upgraded the new engine, all scrolling was disabled (blocked). So looking around the web, I saw that I need to add a preference for enabling scrolling. I'd imagine this is tied to the engine since it worked with the default Cordova engine. It would be great to see the list of preferences that enhance this engine. I'd be more than happy to submit a PR to improve documentation, but I just need to find that list.
3) I'll investigate various ways for monitoring performance and can open a PR to include that in your documentation to help future users.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

BorntraegerMarc picture BorntraegerMarc  路  5Comments

yelhouti picture yelhouti  路  5Comments

jamesdixon picture jamesdixon  路  4Comments

50l3r picture 50l3r  路  7Comments

paulstelzer picture paulstelzer  路  8Comments