asset_manifest 1.0.0.pre.rc2 → 1.0.0.pre.rc3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3a0f6b6cde441c3b7be6227843b40b3ff53c09c4
4
- data.tar.gz: 394e37f6a598e5a71f8418b53a58b841df140215
3
+ metadata.gz: 0288edf09e8d73ad8319a36c6e04feb447951eb0
4
+ data.tar.gz: 06f4e71de159b6edc7140b4a374a7893de1d8442
5
5
  SHA512:
6
- metadata.gz: 63b47c66b9ae393d2c182b0d03348d071b1a11ff9571d72999b37a5861d9c2d49ad9a9ad95186858590c6660362e6cd90aa6c44ab928bcd33293d614f6ada2a5
7
- data.tar.gz: 1afaf14557151c8c0796582f7029c1c91b264461154d80c0e44e064977f59a40a9470307df843deaeb90d08a64a0d163e142e972ca8d9ccd627a91c636a1aa92
6
+ metadata.gz: a85497a49b8bd2ee0935abda14dfab3790de8998b7e1d469c2169ffabfb13eafdb50a28fb039d4e8f3303bbf0674e7228aa7289eb1edf63db7650c428adef858
7
+ data.tar.gz: 513b13dd58fb6cc72cd7a3726f58d8567a871c939f6197a52ed24a7f31b71720e4ea17415584b0c30f38b89e3edb3d160c95b5495f82f9efaecadf9eeb9b0d3c
@@ -5,6 +5,7 @@ module AssetManifest
5
5
  def initialize(manifest, asset_options = {})
6
6
  @manifest = manifest
7
7
  @asset_options = asset_options
8
+ @minify = asset_options.delete(:minify) { nil }
8
9
  end
9
10
 
10
11
  # Public: Generate a <link> tag.
@@ -32,7 +33,7 @@ module AssetManifest
32
33
  # Returns a String.
33
34
  def stylesheet_tag(path, html: {}, **opts)
34
35
  html.update(rel: "stylesheet")
35
- link_tag(path, html: html, **opts)
36
+ link_tag(path, html: html, **opts.merge(minify: @minify))
36
37
  end
37
38
 
38
39
  # Public: Generate a <script> tag to a JS file.
@@ -44,7 +45,7 @@ module AssetManifest
44
45
  #
45
46
  # Returns a String.
46
47
  def script_tag(path, html: {}, **opts)
47
- script = asset(path, opts)
48
+ script = asset(path, opts.merge(minify: @minify))
48
49
  attrs = attributes(html)
49
50
  attrs.concat(sri(script))
50
51
  %Q(<script src="#{script.url}" #{attrs.join(" ")}></script>)
@@ -1,3 +1,3 @@
1
1
  module AssetManifest
2
- VERSION = "1.0.0.pre.rc2".freeze
2
+ VERSION = "1.0.0.pre.rc3".freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asset_manifest
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.pre.rc2
4
+ version: 1.0.0.pre.rc3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nicolas Sanguinetti