sht_rails 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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 55986001ebb59627ef7ace326b839c1cce329e5b
4
- data.tar.gz: a01c33c272d56e7d44ddb6516b98ff551bfed07d
3
+ metadata.gz: 6f8eda11972fbcbe42b2c2ccdde61bbbb41bcbcb
4
+ data.tar.gz: 26691332a87a993617f3c6df24624f35a05ececa
5
5
  SHA512:
6
- metadata.gz: d1451ce66f311d3da13e3925451020e16d9c44823af0a32b6b4ada4bb9414778b0b06d55ac9d9a63954072526dfd71e3faecfcfe02e52793ea60594c6895c201
7
- data.tar.gz: a55ff6774ffacb45bba3714396540c6de7d148119c98efd02764c271bbeda74247551102ff8ec4dde13ba43ccc9f87426b92f981a8c89f516071bf401aee9845
6
+ metadata.gz: f481e298334fa2826a7ff0475f1a55d47871aee8e1acac69d34b2bd959caa6f54aeaa04a89ace2a1cb174dc1425ccec8259dc0c39731ad80db2a30856471d1ad
7
+ data.tar.gz: af93f3405273c7e603317251b250091eff0b6cb2c0599b6ef61859965a493cc690c3db269e37ac3fc8b175617d0f452ba89163373353d5d792e35d308db18933
@@ -1 +1 @@
1
- 2.0.0
1
+ 2.1.1
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # ShtRails
2
2
 
3
- Shared handlebars templates for rails 3.
3
+ Shared handlebars templates for rails 3 and 4.
4
4
 
5
5
  ## Installation
6
6
 
@@ -30,7 +30,7 @@ File: "app/templates/tests/_test.handlebars"
30
30
 
31
31
  In view you can render this template by this way:
32
32
 
33
- <%= render "tests/test", :handlebars => {msg: "Test"} %>
33
+ <%= render "tests/test", :handlebars => {msg: "Test"} %>
34
34
 
35
35
  The same template you can render in JavaScript:
36
36
 
@@ -9,7 +9,7 @@ module ShtRails
9
9
  @context ||= begin
10
10
  context = ::Handlebars::Context.new
11
11
  if helpers = Rails.application.assets.find_asset(ShtRails.helper_path)
12
- context.runtime.eval helpers.source
12
+ context.instance_variable_get(:@js).eval helpers.source
13
13
  end
14
14
  partials.each { |key, value| context.register_partial(key, value) } if partials
15
15
  context
@@ -24,7 +24,7 @@ module ShtRails
24
24
  <<-HandlebarsTemplate
25
25
  (function() {
26
26
  #{namespace} || (#{namespace} = {});
27
- #{namespace}[#{template_key.inspect}] = Handlebars.template(#{precompile(data)});
27
+ Handlebars.partials[#{template_key.inspect}] = #{namespace}[#{template_key.inspect}] = Handlebars.template(#{precompile(data)});
28
28
  }).call(this);
29
29
  HandlebarsTemplate
30
30
  end
@@ -1,3 +1,3 @@
1
1
  module ShtRails
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,97 +1,97 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sht_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexey Vasiliev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-05 00:00:00.000000000 Z
11
+ date: 2014-03-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: 3.1.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: 3.1.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: tilt
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: 1.3.3
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: 1.3.3
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: sprockets
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: 2.0.3
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: 2.0.3
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: handlebars
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: 0.4.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: 0.4.0
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: execjs
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - '>='
73
+ - - ">="
74
74
  - !ruby/object:Gem::Version
75
75
  version: 0.3.0
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - '>='
80
+ - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: 0.3.0
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: rake
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - '>='
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
89
  version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - '>='
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  description: Shared handlebars templates for rails 3
@@ -103,8 +103,8 @@ extra_rdoc_files:
103
103
  - LICENSE
104
104
  - README.md
105
105
  files:
106
- - .gitignore
107
- - .ruby-version
106
+ - ".gitignore"
107
+ - ".ruby-version"
108
108
  - Gemfile
109
109
  - LICENSE
110
110
  - README.md
@@ -125,22 +125,22 @@ licenses: []
125
125
  metadata: {}
126
126
  post_install_message:
127
127
  rdoc_options:
128
- - --charset=UTF-8
128
+ - "--charset=UTF-8"
129
129
  require_paths:
130
130
  - lib
131
131
  required_ruby_version: !ruby/object:Gem::Requirement
132
132
  requirements:
133
- - - '>='
133
+ - - ">="
134
134
  - !ruby/object:Gem::Version
135
135
  version: '0'
136
136
  required_rubygems_version: !ruby/object:Gem::Requirement
137
137
  requirements:
138
- - - '>='
138
+ - - ">="
139
139
  - !ruby/object:Gem::Version
140
140
  version: '0'
141
141
  requirements: []
142
142
  rubyforge_project:
143
- rubygems_version: 2.2.1
143
+ rubygems_version: 2.2.2
144
144
  signing_key:
145
145
  specification_version: 4
146
146
  summary: Shared handlebars templates for rails 3