Sha256: e83888ee2b21eab8a80abedfa6e409e8516a4c758ff16c1047169fbe993fc521
Contents?: true
Size: 572 Bytes
Versions: 5
Compression:
Stored size: 572 Bytes
Contents
# frozen_string_literal: true require "hanami/utils/hash" module Hanami module View module Rendering # Rendering options # # @since 1.1.1 # @api private class Options # @since 1.1.1 # @api private def self.build(options, locals, format) Utils::Hash.deep_dup(options).tap do |opts| opts[:format] = format opts[:locals] = locals opts[:locals].merge!(options.fetch(:locals) { ::Hash.new }).merge!(format: format) end end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems