Image urls for Rails 4 + Less not including the hash
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have a Rails 4 application and am using the less-rails gem. In main.css.less , I add a background image to the site using: body { background-image: image-url("background.jpg"); } Everything works fine locally, but when I push up to my server with precompiled assets, the image url is not updating to include the hash. That is, the image now lives at public/assets/background-074c0b767cd8cfb2da93b37ea3596326.jpg but my css file still says url(/assets/background.jpg) . The link below seemed very promising, but none of the recommended solutions