Handleling image size on multiple device display on cordova-ionic-angular app

末鹿安然 提交于 2019-12-06 04:59:00
jnsnvt

There really isn't a single way to do this since each implementation of an image will require a different approach depending on its purpose. SVGs are great but not everything works as an SVG.

Media queries will be your ally.

See this: supporting multiple resolution and density of images in phonegap

and this for an alternate approach: Angular.js data-bind background images using media queries

There are also some nice polyfills for the html5 picture element which you might find useful.

See: https://github.com/scottjehl/picturefill

...and its angularjs directive implementation https://github.com/tinacious/angular-picturefill

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!