We are doing some dynamic loading of content on our HTTPS site.
The url used comes directly from portal.componentUrl
Since portal.componentUrl does not know that the site is HTTPS it uses http not https (as it should).
We have configured our proxy server to set the X-Forwarded-Proto header, so I can do this:
const proto = request.headers && request.headers['X-Forwarded-Proto'] || 'http';
Instead of doing string replace in js, it would be nice if componentUrl supported a “proto” option.
I guess that would be nice for all url methods.
Maybe they could respect the X-Forwarded-Proto header, but I don’t know what side-effects that might cause.