How to use sass-rails helpers in Ruby?
问题 From the Github page it would seem that one can use the Sass helpers ( asset_path , asset_url , image_path etc.) in Ruby but I can't figure out how. I need to set the default_url for a Paperclip attachment and want to use one of my assets from the asset pipeline for that. 回答1: You can use the sass helpers in SCSS files, but you cannot use them elsewhere. In those cases you need to use the regular asset_path and image_tag helpers. 来源: https://stackoverflow.com/questions/7636204/how-to-use-sass