Ionic iframe loading error

When I try to load api response in ionic iframe it gives me Error : Uncaught (in promise): SecurityError: Failed to execute ‘open’ on ‘Document’: Can only call open() on same-origin documents. I have searched on many forums and it says api response header should allow any origin. I have already set this line of code “header(‘Access-Control-Allow-Origin: *’);” in api. But I am still getting above error. Please help

1 Like

R u test app by live reload ??

@demokumar what exactly you mean?

i mean to run app which commend u use ionic cordova run android or ionic cordova run android -l -c