Sha256: 34c9ffd1f945aabad7a8f92c8c6b6bd5c23eba22bdfdd393a1e458908a3f4561
Contents?: true
Size: 464 Bytes
Versions: 3
Compression:
Stored size: 464 Bytes
Contents
module Propshaft::Resolver class Dynamic attr_reader :load_path, :prefix def initialize(load_path:, prefix:) @load_path, @prefix = load_path, prefix end def resolve(logical_path) if asset = load_path.find(logical_path) File.join prefix, asset.digested_path end end def read(logical_path, options = {}) if asset = load_path.find(logical_path) asset.content(**options) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
propshaft-1.1.0 | lib/propshaft/resolver/dynamic.rb |
propshaft-1.0.1 | lib/propshaft/resolver/dynamic.rb |
propshaft-1.0.0 | lib/propshaft/resolver/dynamic.rb |