In cases where the Vizlib Library is loaded into mashups or web apps not hosted on the same server as Qlik Sense, you may run into an error where loaded charts are displaying an "Invalid visualization" error.
The console log error typically indicates:
Issue:
CORS is not enabled on you virtual proxy, hence Preflight request from javascript (HTTP OPTIONS to https://hostname/qrs/extension/schema?xrfkey=xrfkey) does not return "Access-Control-Allow-Origin" response header. So the access to custom extensions is blocked.
Steps to Resolve:
To resolve this issue all you need to do is enable the following setting on your virtual proxy:
Added response header "Access-Control-Allow-Origin: * " to the preflight request and below is the custom extension rendered without any issue.