Module: Jekyll::Assets::Patches::SassFunctions

Included in:
Sprockets::SassProcessor::Functions
Defined in:
lib/jekyll/assets/patches/functions.rb

Constant Summary collapse

SprocketsString =
::Sprockets::Autoload::Sass::Script::String

Instance Method Summary collapse

Instance Method Details

#asset_path(path, options = {}) ⇒ Object



11
12
13
14
15
16
# File 'lib/jekyll/assets/patches/functions.rb', line 11

def asset_path(path, options = {})
  path, args = path.value.split(%r!\s+!, 2)
  path, fragment = URI.split(path).values_at(5, 8)
  path = sprockets_context.asset_path("#{path} #{args}", options)
  SprocketsString.new [path, fragment].compact.join("#")
end