rodneyrehm / viewport-units-buggyfill

Making viewport units (vh|vw|vmin|vmax) work properly in Mobile Safari.
MIT License
1.59k stars 151 forks source link

Cannot load the corresponding background image. #96

Closed ZeroJsus closed 6 years ago

ZeroJsus commented 6 years ago

In the mobile background image, polyfill cannot load the corresponding image. &::before{ content:''; width: 50px; height: 50px; display: block; margin: 1px auto 0 auto; background-image: url('./../assets/images/footericon.png'); background-repeat: no-repeat; background-size: 400%; } Polyfill in the mobile background image cannot load the corresponding background image.

The error message : net::ERR_INVALID_URL

rodneyrehm commented 6 years ago

I don't quite understand the problem. The example code is not using any viewport units, so I don't see the problem. What does the DevTools say about the element's styles?

ZeroJsus commented 6 years ago

Thank you for answering my question. 😄 😄 😄 I use vue this is a vue component in the update style should be due to the path problem causing the image to load failed. Here's the wrong message. GET data:image/png;base64,iVBO... Failed to load resource net::ERR_INVALID_URL updateStyles @ viewport-units-buggyfill.js?708a:188 (anonymous) @ viewport-units-buggyfill.js?708a:205 So how do I fix this path?

ZeroJsus commented 6 years ago

Problem solved!!! I use Githubissues.

  • Githubissues is a development platform for aggregating issues.