Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rails 3.1 Asset pipeline - IE not loading all stylesheets in development

Testing my site in Internet Explorer (testing with IE 9 at the moment) I saw many things wrong but quite a few things that I thought shouldn't be wrong.

It turns out that IE isn't applying all the stylesheets in development mode (verified by adding a body { border: 10px solid blue; } rule to one of the stylesheets).

I've opened up the development tools and done network capturing and it reports they're all loaded (result: 304).

I've tried running the server both through Webrick & thin.

Only thing I can think is it's just too many stylesheets for IE to cope with. The only way I've got it to work is by pre-compiling the assets and running the server in production mode. But this is of course far from ideal.

like image 283
DEfusion Avatar asked Dec 21 '22 08:12

DEfusion


1 Answers

Yuck IE imposes a 31 stylesheet limit: http://social.msdn.microsoft.com/Forums/en-US/iewebdevelopment/thread/ad1b6e88-bbfa-4cc4-9e95-3889b82a7c1d/

The only way I found around this in development is to change my settings to:

config.assets.compile = true
config.assets.debug = false
like image 175
DEfusion Avatar answered Apr 28 '23 00:04

DEfusion