module Sprockets::Rails::Helper

def asset_digest_path(path, options = {})

Returns String path or nil if no asset was found.

options - Hash options
path - String path

Expand asset path to digested form.
def asset_digest_path(path, options = {})
  if manifest = assets_manifest
    if digest_path = manifest.assets[path]
      return digest_path
    end
  end
  if environment = assets_environment
    if asset = environment[path]
      return asset.digest_path
    end
  end
end