Run webView with https

Hi guys,
I am trying to run my Ionic application with capacitor but i need the webview url to start with https. For corodova I can configure that in the config.xml with scheme, but I can’t find a solution for capaciotor?

@mhartington, this is also my concern. Can you give us some suggestion?
Many thanks.

Update Capacitor to 1.2.0, it was just released with that new feature

For those who are stuck on that since the documentation is not yet updated. In the capacitor.config.json
in the server section:
“server”: {
“hostname”: “localhost:3000”,
“iosScheme”: “https”,
“androidScheme”: “https”

on iOS you can’t use https, that should default to capacitor://

Is that right for Cordova also

In cordova it defaults to ionic://

This is kind of a big problem. Many 3rd parties require https origins these days. Any work arounds?

Are you sure about that? This thread seems specifically to be about Ionic internals, so:

I’m not seeing how 3rd parties would be involved at all in how the Ionic app gets at stuff that’s baked into its bundle.

Can you describe the problem you’re actually encountering? If it doesn’t have to do with stuff that’s bundled with the app, maybe a new thread would be a better choice than this one.

Perhaps my issue is a lack of understanding, or documentation. Please help clarify for me.

So if the app itself is running the webview without https/ssl -does it still communicate with outside APIs securely?

Last question, the third-party example was a reference to Stripe payments. Their frontend JS library embeds some payment UI controls, and insists that the site it’s embedded in is using https. This seems like if would be effected by the http webview, is that not right?

Yes, as long as you’re passing https: URLs to libraries that fire off XHRs (such as Angular HttpClient).

I’ve used Stripe, and I’ve written Ionic apps, but haven’t yet done the two together. This cordova plugin claims to be able to interact with Stripe in Ionic apps (and there’s an Ionic Native shim). I would think that if you had to jump through any additional hoops to get that to work, it would be documented there.