lib/hanami/assets/configuration.rb in hanami-assets-1.3.0 vs lib/hanami/assets/configuration.rb in hanami-assets-1.3.1
- old
+ new
@@ -127,10 +127,21 @@
else
@fingerprint = value
end
end
+ # Support for nested path
+ #
+ # @since 1.3.1
+ def nested(value = nil)
+ if value.nil?
+ @nested
+ else
+ @nested = !!value # rubocop:disable Style/DoubleNegation
+ end
+ end
+
# Subresource integrity mode
#
# Determine if the helpers should generate the integrity attribute for an
# asset. Usually this is turned on in production mode.
#
@@ -504,10 +515,11 @@
c.port = port
c.prefix = prefix
c.subresource_integrity = subresource_integrity
c.cdn = cdn
c.compile = compile
+ c.nested = nested
c.public_directory = public_directory
c.manifest = manifest
c.sources = sources.dup
c.javascript_compressor = javascript_compressor
c.stylesheet_compressor = stylesheet_compressor
@@ -524,10 +536,11 @@
@prefix = Utils::PathPrefix.new(DEFAULT_PREFIX)
@subresource_integrity = false
@cdn = false
@fingerprint = false
@compile = false
+ @nested = false
@base_url = nil
@destination_directory = nil
@public_manifest = Config::NullManifest.new(self)
@javascript_compressor = nil
@@ -566,9 +579,13 @@
attr_writer :cdn
# @since 0.1.0
# @api private
attr_writer :compile
+
+ # @since 1.3.1
+ # @api private
+ attr_writer :nested
# @since 0.1.0
# @api private
attr_writer :scheme