sprockets-emblem 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/sprockets/emblem.rb +12 -8
- data/sprockets-emblem.gemspec +3 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 082260ac97badebe993fd4aec4d480899ab6e136
|
4
|
+
data.tar.gz: f06102c0007d6abb4a3dff910cf8a95112338162
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 914b1f64889481a024b1e5914d2562d8732ea7d79e980867444390ff0dc602a768756d508244000129d34081b6f2889351b5b37adf5621b460832de1380203f3
|
7
|
+
data.tar.gz: 5d6690eb0386e9f806222452023775d12bae1dd8664290a9cb6e010c84f33df738f5fad75b9e36acdc524576d386b4de64566e2952e619d9c64d68e415d7ffa1
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.2
|
data/lib/sprockets/emblem.rb
CHANGED
@@ -16,7 +16,7 @@ module Sprockets
|
|
16
16
|
end
|
17
17
|
|
18
18
|
def evaluate(scope, locals, &block)
|
19
|
-
compiled_hbs = context.call('Emblem.precompile',
|
19
|
+
compiled_hbs = context.call('Emblem.precompile', HandlebarsVariant, data)
|
20
20
|
"Handlebars.template(#{compiled_hbs});"
|
21
21
|
end
|
22
22
|
|
@@ -29,15 +29,19 @@ module Sprockets
|
|
29
29
|
HandlebarsAssets::Handlebars.send :source
|
30
30
|
end
|
31
31
|
|
32
|
-
def
|
33
|
-
@hbs_variant ||= begin
|
34
|
-
'Handlebars'.tap do |hbs|
|
35
|
-
hbs.define_singleton_method(:encode_json) { |encoder| hbs }
|
36
|
-
end
|
37
|
-
end
|
32
|
+
def prepare
|
38
33
|
end
|
39
34
|
|
40
|
-
|
35
|
+
module HandlebarsVariant
|
36
|
+
VARIANT = 'Handlebars'.freeze
|
37
|
+
|
38
|
+
def self.to_json(options = nil)
|
39
|
+
VARIANT
|
40
|
+
end
|
41
|
+
|
42
|
+
def self.encode_json(encoder = nil)
|
43
|
+
VARIANT
|
44
|
+
end
|
41
45
|
end
|
42
46
|
end
|
43
47
|
end
|
data/sprockets-emblem.gemspec
CHANGED
@@ -2,16 +2,16 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: sprockets-emblem 0.2.
|
5
|
+
# stub: sprockets-emblem 0.2.2 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "sprockets-emblem"
|
9
|
-
s.version = "0.2.
|
9
|
+
s.version = "0.2.2"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib"]
|
13
13
|
s.authors = ["Roman Shterenzon"]
|
14
|
-
s.date = "2015-02
|
14
|
+
s.date = "2015-03-02"
|
15
15
|
s.description = "Sprockets integration for Emblem.js"
|
16
16
|
s.email = "romanbsd@yahoo.com"
|
17
17
|
s.extra_rdoc_files = [
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sprockets-emblem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Roman Shterenzon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-02
|
11
|
+
date: 2015-03-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: emblem-source
|