module Middleman::Sass::Functions

def font_url(source, options={})


src: font-url("image.jpg", $digest: true); // src: url("/assets/font-27a8f1f96afd8d4c67a59eb9447f45bd.ttf");
src: font-url("font.ttf"); // src: url("/assets/font.ttf");

=== Examples

arguments that mirror the +options+.
for the given +source+ as a Sass String. This supports keyword
Using Middleman::Util#asset_path, return the url CSS
def font_url(source, options={})
  # Work with the Sass #font_url API
  if options.respond_to? :value
    case options.value
    when true
      return font_path source
    else
      options = {}
    end
  end
  ::SassC::Script::Value::String.new "url(#{font_path(source, options)})"
end