leikind/wice_grid — pull request #165 by dontfidget (2014-07-28 04:36:30+00:00)
Title: rails4 asset pipeline support

Thanks for grabbing my last pull requests. I'm not sure I've got this one quite right (because to do that I'd have to fully understand the rails asset pipeline and sprockets and I think there may be only one or two people in the whole world like that. ;).

So what I'm doing here is using the image-url helpers so that I get a fingerprinted asset name, and I'm explicitly adding the wice_grid assets to the precompile list so that they are generated. I'm using rails4 and I had trouble in production with the assets because rails4 no longer automatically precompiles assets from vendor gems. I've been looking for some online guidance that tells all gem owners with image assets that they should be explicitly precompiling their assets and using the image-url helper to ensure that (a) they get fingerprinted assets and (b) their css is dependent on those fingerprints (I think image-url implicitly creates this dependency, but I could be wrong). I haven't found anything explicitly saying all this, but that's my takeaway from what I've read.