About the cross-domain problem of the plug-in vue-qr

error report:
Access to Image at"https://img.codeshelper.com/upload/img/2021/03/13/uef0t21ij4j7750 "http://xxx.yyyyyyyy.com/app/package/2ec8bab90c794f208b6c2137a50dd9db.png" rel=" nofollow noreferrer "> http://xxx.yyyyyyyy.com/app/p." from origin"https://img.codeshelper.com/upload/img/2021/03/13/uef0t21ij4j7750" http://localhost" rel= "nofollow noreferrer" > http://localhost:9527" has been blocked by CORS policy: No "Access-Control-Allow-Origin" header is present on the requested resource. Origin"https://img.codeshelper.com/upload/img/2021/03/13/uef0t21ij4j7750 "http://localhost" rel=" nofollow noreferrer "> http://localhost:9527" is therefore not allowed access.
however,
if you use the img tag directly, you can display the picture
http://xxx.yyyyyyyy.com/app/p.;>

.

have you come across it? is there any good plan?

Mar.13,2021

src is not affected by cross-domain, and the principle of jsonp cross-domain is based on this. In the case of vue, just configure the agent in the scaffolding. Or you can solve cross-domain problems with fetch,. A new one is cute. Just take a look at it.

Menu