louisremi / background-size-polyfill

Adds support for background-size "cover" and "contain" to IE8
http://louisremi.github.com/background-size-polyfill/
MIT License
1.26k stars 359 forks source link

backgroundsizemin.htc (apparently) fails to load in angularjs app #28

Closed dsmithhfx closed 10 years ago

dsmithhfx commented 10 years ago

Hi,

I'm testing out your plugin in an angularjs app that's using background-size in a few places (of course breaking in IE8).

On my dev server, the downloaded and unzipped background-size-polyfill bundle is loading and working fine (so, not a server issue). However, in the angular app the script isn't doing anything. I think I've narrowed the problem down to the default angular project/app/.htaccess (which has "AddType text/x-component htc" on board, inside <IfModule mod_mime.c></IfModule>), OR (maybe) a jquery version incompatibility.

I've got the google cdns of jquery.min 1.10.2, and jquery-ui.min 1.10.3 being loaded in the body after ng-view templates, and custom css (with backgroundsizemin.htc) loading conditionally from a lt IE9 statement in the header.

What am I missing? Any ideas on how to go about fixing this? Thanks.

louisremi commented 10 years ago

Are the .htaccess and the polyfill at the root of your website? Is your webserver Apache? There are no jQuery incompatibility AFAIK, as it isn't a dependency.

dsmithhfx commented 10 years ago

Hi, I got it working. For whatever reason my angular config doesn't like the minified polyfill. The 'full' (unminified) backgroundsize.htc works. Thanks for responding!

louisremi commented 10 years ago

Alright, good to know!