adzap-mustache-rails 0.3.2 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/action_view/mustache.rb +2 -2
- data/lib/action_view/template/handlers/mustache.rb +3 -3
- metadata +24 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1bcdade882760131f18cca8c7b633565c519a40d19bcfef423fd560288c0f97f
|
4
|
+
data.tar.gz: 149278f2bef4320c78428fc2ec5da51c509e037d6902f2e3908cf65d68a5039e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8be91323936ee374dbcfc0923e383bfe14f5223d9842cf25e50e7c1bdee9ca006ab48708a923edf02f799a3fdb3dc2c109d502365eafd070cde48771efb5547f
|
7
|
+
data.tar.gz: 54a70b006bb28086df1818ea7d7726facd2ddf25d93c3b70a5223911b7e79d3fa23bfa41b0fa5e90c8ad1ff2853b024b55fedaa63f3221da396544db95624c85
|
data/lib/action_view/mustache.rb
CHANGED
@@ -63,8 +63,8 @@ module ActionView
|
|
63
63
|
# Public: Forwards methods to original Rails view context
|
64
64
|
#
|
65
65
|
# Returns an Object.
|
66
|
-
def method_missing(*args, &block)
|
67
|
-
@_view.send(*args, &block)
|
66
|
+
def method_missing(*args, **kwargs, &block)
|
67
|
+
@_view.send(*args, **kwargs, &block)
|
68
68
|
end
|
69
69
|
|
70
70
|
# Public: Checks if method exists in Rails view context.
|
@@ -21,14 +21,14 @@ module ActionView
|
|
21
21
|
# template - ActionView::Template object
|
22
22
|
#
|
23
23
|
# Returns String of Ruby code to be evaled.
|
24
|
-
def self.call(template)
|
24
|
+
def self.call(template, source)
|
25
25
|
# Use standard mustache parser to generate tokens
|
26
|
-
tokens = ::Mustache::Parser.new.compile(
|
26
|
+
tokens = ::Mustache::Parser.new.compile(source)
|
27
27
|
|
28
28
|
# Use custom generator to generate the compiled ruby
|
29
29
|
src = ActionView::Mustache::Generator.new.compile(tokens)
|
30
30
|
|
31
|
-
digest = Digest::MD5.hexdigest(
|
31
|
+
digest = Digest::MD5.hexdigest(source)[0, 10]
|
32
32
|
set_cache_key = "merge({:template_cache_key => \"#{digest}\"})"
|
33
33
|
|
34
34
|
<<-RUBY
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: adzap-mustache-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Meehan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-12-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionpack
|
@@ -16,20 +16,20 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
20
|
-
- - "
|
19
|
+
version: '6.0'
|
20
|
+
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version:
|
22
|
+
version: '7'
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: '
|
30
|
-
- - "
|
29
|
+
version: '6.0'
|
30
|
+
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version:
|
32
|
+
version: '7'
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: mustache
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -44,6 +44,20 @@ dependencies:
|
|
44
44
|
- - "~>"
|
45
45
|
- !ruby/object:Gem::Version
|
46
46
|
version: 1.1.0
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: test-unit
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
50
|
+
requirements:
|
51
|
+
- - ">="
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
54
|
+
type: :development
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
requirements:
|
58
|
+
- - ">="
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: '0'
|
47
61
|
- !ruby/object:Gem::Dependency
|
48
62
|
name: rake
|
49
63
|
requirement: !ruby/object:Gem::Requirement
|
@@ -58,7 +72,7 @@ dependencies:
|
|
58
72
|
- - ">="
|
59
73
|
- !ruby/object:Gem::Version
|
60
74
|
version: '0'
|
61
|
-
description: Implements Mustache views and templates for Rails
|
75
|
+
description: Implements Mustache views and templates for Rails 6.x
|
62
76
|
email: adam.meehan@gmail.com
|
63
77
|
executables: []
|
64
78
|
extensions: []
|
@@ -100,7 +114,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
100
114
|
- !ruby/object:Gem::Version
|
101
115
|
version: '0'
|
102
116
|
requirements: []
|
103
|
-
rubygems_version: 3.
|
117
|
+
rubygems_version: 3.1.6
|
104
118
|
signing_key:
|
105
119
|
specification_version: 4
|
106
120
|
summary: Mustache Rails adapter
|