Sha256: 4bcef45d8814ec06331499f92a2b02702914142b2df1955b8406284bfaa8cdbf
Contents?: true
Size: 622 Bytes
Versions: 2
Compression:
Stored size: 622 Bytes
Contents
# frozen_string_literal: true module KepplerFrontend module LiveEditor # CssHandler class ImagesHandler def initialize; end def output images = Dir["#{core_app}/*"] arr = [] images.each do |i| arr << { type: 'image', src: front_app(i.split('/').last).to_s } end arr end private def front_app(file) urls = KepplerFrontend::Urls::Assets.new urls.front_assets(file) end def core_app urls = KepplerFrontend::Urls::Assets.new urls.core_assets('images', 'app') end end end end
Version data entries
2 entries across 2 versions & 1 rubygems