Sha256: fffe5d61be24699dd8b5fc7854a75ac61704ac18ddc6e76cca116196aea9c055

Contents?: true

Size: 468 Bytes

Versions: 6

Compression:

Stored size: 468 Bytes

Contents

# Provides a base singleton-configuration pattern for loading a file, given a path
class Webpacker::FileLoader
  class NotFoundError < StandardError; end
  class FileLoaderError < StandardError; end

  class_attribute :instance
  attr_accessor :data

  class << self
    def load(path = file_path)
      self.instance = new(path)
    end
  end

  private
    def initialize(path)
      @path = path
      @data = load
    end

    def load
      {}.freeze
    end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
webpacker-legacy-0.1.2 lib/webpacker/file_loader.rb
webpacker-legacy-0.1.1 lib/webpacker/file_loader.rb
webpacker-legacy-0.1.0 lib/webpacker/file_loader.rb
webpacker-2.0 lib/webpacker/file_loader.rb
webpacker-1.2 lib/webpacker/file_loader.rb
webpacker-1.1 lib/webpacker/file_loader.rb