webpack-assets 0.2.1 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/webpack/assets/version.rb +1 -1
- data/lib/webpack/view_helpers.rb +6 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ab2fc0d5850ec8336921ef93ed7bc141b334096
|
4
|
+
data.tar.gz: 2bfc978c7ecb48c8d2b02d1c749821cc1c797acc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 682f2ce352c5b1b67222779ad8e97dd3302cbc8fd13f2fa3b74bae5c7e61d78118630a64d0d6bcd99255f0a2802895cd96d88d19c71323950df6930013a99e31
|
7
|
+
data.tar.gz: 92cb7a1e2a3974fb38b71cfe9b6cf57833ce6c3f333766e7148d3ddae4ad2c5118f160a678d1d510afd1307d6ec44a6d6968015bfeff3ab1e86529d70169b297
|
data/lib/webpack/view_helpers.rb
CHANGED
@@ -48,7 +48,7 @@ module Webpack
|
|
48
48
|
else
|
49
49
|
static_file = Webpack.fetch_static_file("#{Webpack.config.static_path}/#{path}")
|
50
50
|
if Webpack.config.cdn_host.present?
|
51
|
-
"
|
51
|
+
"#{protocol}#{Webpack.config.cdn_host}#{static_file}"
|
52
52
|
else
|
53
53
|
static_file
|
54
54
|
end
|
@@ -57,8 +57,12 @@ module Webpack
|
|
57
57
|
|
58
58
|
private
|
59
59
|
|
60
|
+
def protocol
|
61
|
+
@view_context.request.protocol.presence || '//'
|
62
|
+
end
|
63
|
+
|
60
64
|
def server_url(path)
|
61
|
-
"
|
65
|
+
"#{protocol}#{server_host}#{Webpack.config.public_path}/#{path}"
|
62
66
|
end
|
63
67
|
|
64
68
|
def server_host
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: webpack-assets
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sergey Nartimov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionpack
|
@@ -124,7 +124,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
124
124
|
version: '0'
|
125
125
|
requirements: []
|
126
126
|
rubyforge_project:
|
127
|
-
rubygems_version: 2.4.
|
127
|
+
rubygems_version: 2.4.5
|
128
128
|
signing_key:
|
129
129
|
specification_version: 4
|
130
130
|
summary: Webpack Assets for Rails.
|