Module: Awestruct::Extensions::Assets

Defined in:
lib/awestruct/extensions/assets.rb

Defined Under Namespace

Classes: Transformer

Instance Method Summary collapse

Instance Method Details

#asset(href) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/awestruct/extensions/assets.rb', line 8

def asset(href)
  if site.assets_url
    File.join(site.assets_url, href)
  else
    relative(File.join("/#{site.assets_path||'assets'}", href))
  end
end