coffee-views 0.1.7 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/coffee-views.gemspec +2 -2
- data/lib/coffee_views/slim.rb +5 -5
- data/lib/coffee_views/version.rb +1 -1
- data/spec/dummy/db/.keep +0 -0
- data/spec/dummy/db/schema.rb +16 -0
- data/spec/views/events_spec.rb +1 -3
- metadata +53 -75
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 5cd6ebf67e762eb4fc9dde9008c90bfb3a2f9b57
|
4
|
+
data.tar.gz: f913b1213a24a37b7314e0db9b2786b283ff46a3
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 813592b3e78ba2553b0cd7869c4ac6f8939726da4d7e4de73a32c1d62e5e32f730aa7bde9ea9c1ff8c1bdeb5ef283c605cbc9dd11dafc4b2e9ac37ce8752d5d7
|
7
|
+
data.tar.gz: 7effef2ba445837969faaa535e4cbcaa285b05e183788c44eeb22bbbf1f823d912e7b12b2f12ae66853f09f3052708dd2638aed2be64164fbe273dd038e119a2
|
data/coffee-views.gemspec
CHANGED
@@ -15,8 +15,8 @@ Gem::Specification.new do |s|
|
|
15
15
|
|
16
16
|
s.files = `git ls-files`.split("\n")
|
17
17
|
s.require_path = 'lib'
|
18
|
-
|
19
|
-
s.add_dependency "rails", ">= 3.2.0"
|
18
|
+
|
19
|
+
s.add_dependency "rails", ">= 3.2.0"
|
20
20
|
s.add_dependency "coffee-rails"
|
21
21
|
s.add_development_dependency "sqlite3"
|
22
22
|
s.add_development_dependency "rspec-rails", "~> 2.6"
|
data/lib/coffee_views/slim.rb
CHANGED
@@ -3,7 +3,7 @@ ActiveSupport.on_load(:action_view) do
|
|
3
3
|
if Object.const_defined?(:Slim)
|
4
4
|
|
5
5
|
module CoffeeViews
|
6
|
-
class CoffeeViewEngine < Slim::
|
6
|
+
class CoffeeViewEngine < Slim::Embedded::ERBEngine
|
7
7
|
def on_slim_embedded(engine, body)
|
8
8
|
erb = collect_text(body)
|
9
9
|
source = CoffeeViews::Rails::TemplateHandler.compile_coffee(erb)
|
@@ -22,12 +22,12 @@ ActiveSupport.on_load(:action_view) do
|
|
22
22
|
end
|
23
23
|
end
|
24
24
|
end
|
25
|
-
|
26
|
-
Slim::
|
27
|
-
::Slim::
|
25
|
+
|
26
|
+
Slim::Embedded.register :coffeeview,
|
27
|
+
::Slim::Embedded::TagEngine,
|
28
28
|
:tag => :script,
|
29
29
|
:attributes => { :type => 'text/javascript' },
|
30
30
|
:engine => CoffeeViewEngine
|
31
31
|
end
|
32
32
|
end
|
33
|
-
end
|
33
|
+
end
|
data/lib/coffee_views/version.rb
CHANGED
data/spec/dummy/db/.keep
ADDED
File without changes
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# This file is auto-generated from the current state of the database. Instead
|
3
|
+
# of editing this file, please use the migrations feature of Active Record to
|
4
|
+
# incrementally modify your database, and then regenerate this schema definition.
|
5
|
+
#
|
6
|
+
# Note that this schema.rb definition is the authoritative source for your
|
7
|
+
# database schema. If you need to create the application database on another
|
8
|
+
# system, you should be using db:schema:load, not running all the migrations
|
9
|
+
# from scratch. The latter is a flawed and unsustainable approach (the more migrations
|
10
|
+
# you'll amass, the slower it'll run and the greater likelihood for issues).
|
11
|
+
#
|
12
|
+
# It's strongly recommended to check this file into your version control system.
|
13
|
+
|
14
|
+
ActiveRecord::Schema.define(:version => 0) do
|
15
|
+
|
16
|
+
end
|
data/spec/views/events_spec.rb
CHANGED
@@ -9,7 +9,6 @@ describe "events/index.js.coffee" do
|
|
9
9
|
|
10
10
|
rendered.should == <<-JAVASCRIPT
|
11
11
|
(function() {
|
12
|
-
|
13
12
|
alert("hello, " + "Yury" + " " + 'Korolev');
|
14
13
|
|
15
14
|
}).call(this);
|
@@ -22,11 +21,10 @@ describe "events/index.html.slim" do
|
|
22
21
|
assign :first_name, "Yury"
|
23
22
|
assign :last_name, "'Korolev'"
|
24
23
|
|
25
|
-
render
|
24
|
+
render
|
26
25
|
|
27
26
|
expected = <<-JAVASCRIPT
|
28
27
|
<script type="text/javascript">(function() {
|
29
|
-
|
30
28
|
alert("hello, " + "Yury" + " " + 'Korolev');
|
31
29
|
|
32
30
|
}).call(this);
|
metadata
CHANGED
@@ -1,144 +1,127 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: coffee-views
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
version: 0.1.7
|
4
|
+
version: 0.2.0
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Yury Korolev
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date: 2013-
|
11
|
+
date: 2013-06-04 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: rails
|
16
|
-
version_requirements: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
|
-
requirements:
|
19
|
-
- - ! '>='
|
20
|
-
- !ruby/object:Gem::Version
|
21
|
-
version: 3.2.0
|
22
15
|
requirement: !ruby/object:Gem::Requirement
|
23
|
-
none: false
|
24
16
|
requirements:
|
25
|
-
- -
|
17
|
+
- - '>='
|
26
18
|
- !ruby/object:Gem::Version
|
27
19
|
version: 3.2.0
|
28
|
-
prerelease: false
|
29
20
|
type: :runtime
|
30
|
-
|
31
|
-
name: coffee-rails
|
21
|
+
prerelease: false
|
32
22
|
version_requirements: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
23
|
requirements:
|
35
|
-
- -
|
24
|
+
- - '>='
|
36
25
|
- !ruby/object:Gem::Version
|
37
|
-
version:
|
26
|
+
version: 3.2.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: coffee-rails
|
38
29
|
requirement: !ruby/object:Gem::Requirement
|
39
|
-
none: false
|
40
30
|
requirements:
|
41
|
-
- -
|
31
|
+
- - '>='
|
42
32
|
- !ruby/object:Gem::Version
|
43
33
|
version: '0'
|
44
|
-
prerelease: false
|
45
34
|
type: :runtime
|
46
|
-
|
47
|
-
name: sqlite3
|
35
|
+
prerelease: false
|
48
36
|
version_requirements: !ruby/object:Gem::Requirement
|
49
|
-
none: false
|
50
37
|
requirements:
|
51
|
-
- -
|
38
|
+
- - '>='
|
52
39
|
- !ruby/object:Gem::Version
|
53
40
|
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: sqlite3
|
54
43
|
requirement: !ruby/object:Gem::Requirement
|
55
|
-
none: false
|
56
44
|
requirements:
|
57
|
-
- -
|
45
|
+
- - '>='
|
58
46
|
- !ruby/object:Gem::Version
|
59
47
|
version: '0'
|
60
|
-
prerelease: false
|
61
48
|
type: :development
|
62
|
-
|
63
|
-
name: rspec-rails
|
49
|
+
prerelease: false
|
64
50
|
version_requirements: !ruby/object:Gem::Requirement
|
65
|
-
none: false
|
66
51
|
requirements:
|
67
|
-
- -
|
52
|
+
- - '>='
|
68
53
|
- !ruby/object:Gem::Version
|
69
|
-
version: '
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rspec-rails
|
70
57
|
requirement: !ruby/object:Gem::Requirement
|
71
|
-
none: false
|
72
58
|
requirements:
|
73
59
|
- - ~>
|
74
60
|
- !ruby/object:Gem::Version
|
75
61
|
version: '2.6'
|
76
|
-
prerelease: false
|
77
62
|
type: :development
|
78
|
-
|
79
|
-
name: sass-rails
|
63
|
+
prerelease: false
|
80
64
|
version_requirements: !ruby/object:Gem::Requirement
|
81
|
-
none: false
|
82
65
|
requirements:
|
83
|
-
- -
|
66
|
+
- - ~>
|
84
67
|
- !ruby/object:Gem::Version
|
85
|
-
version: '
|
68
|
+
version: '2.6'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: sass-rails
|
86
71
|
requirement: !ruby/object:Gem::Requirement
|
87
|
-
none: false
|
88
72
|
requirements:
|
89
|
-
- -
|
73
|
+
- - '>='
|
90
74
|
- !ruby/object:Gem::Version
|
91
75
|
version: '0'
|
92
|
-
prerelease: false
|
93
76
|
type: :development
|
94
|
-
|
95
|
-
name: coffee-rails
|
77
|
+
prerelease: false
|
96
78
|
version_requirements: !ruby/object:Gem::Requirement
|
97
|
-
none: false
|
98
79
|
requirements:
|
99
|
-
- -
|
80
|
+
- - '>='
|
100
81
|
- !ruby/object:Gem::Version
|
101
82
|
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: coffee-rails
|
102
85
|
requirement: !ruby/object:Gem::Requirement
|
103
|
-
none: false
|
104
86
|
requirements:
|
105
|
-
- -
|
87
|
+
- - '>='
|
106
88
|
- !ruby/object:Gem::Version
|
107
89
|
version: '0'
|
108
|
-
prerelease: false
|
109
90
|
type: :development
|
110
|
-
|
111
|
-
name: uglifier
|
91
|
+
prerelease: false
|
112
92
|
version_requirements: !ruby/object:Gem::Requirement
|
113
|
-
none: false
|
114
93
|
requirements:
|
115
|
-
- -
|
94
|
+
- - '>='
|
116
95
|
- !ruby/object:Gem::Version
|
117
96
|
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: uglifier
|
118
99
|
requirement: !ruby/object:Gem::Requirement
|
119
|
-
none: false
|
120
100
|
requirements:
|
121
|
-
- -
|
101
|
+
- - '>='
|
122
102
|
- !ruby/object:Gem::Version
|
123
103
|
version: '0'
|
124
|
-
prerelease: false
|
125
104
|
type: :development
|
126
|
-
|
127
|
-
name: slim
|
105
|
+
prerelease: false
|
128
106
|
version_requirements: !ruby/object:Gem::Requirement
|
129
|
-
none: false
|
130
107
|
requirements:
|
131
|
-
- -
|
108
|
+
- - '>='
|
132
109
|
- !ruby/object:Gem::Version
|
133
110
|
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: slim
|
134
113
|
requirement: !ruby/object:Gem::Requirement
|
135
|
-
none: false
|
136
114
|
requirements:
|
137
|
-
- -
|
115
|
+
- - '>='
|
138
116
|
- !ruby/object:Gem::Version
|
139
117
|
version: '0'
|
140
|
-
prerelease: false
|
141
118
|
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - '>='
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
142
125
|
description: Allows you to create .js.coffee views
|
143
126
|
email: yury.korolev@gmail.com
|
144
127
|
executables: []
|
@@ -185,6 +168,8 @@ files:
|
|
185
168
|
- spec/dummy/config/initializers/wrap_parameters.rb
|
186
169
|
- spec/dummy/config/locales/en.yml
|
187
170
|
- spec/dummy/config/routes.rb
|
171
|
+
- spec/dummy/db/.keep
|
172
|
+
- spec/dummy/db/schema.rb
|
188
173
|
- spec/dummy/lib/assets/.gitkeep
|
189
174
|
- spec/dummy/log/.gitkeep
|
190
175
|
- spec/dummy/public/404.html
|
@@ -197,33 +182,26 @@ files:
|
|
197
182
|
- spec/views/events_spec.rb
|
198
183
|
homepage: http://github.com/yury/coffee-views
|
199
184
|
licenses: []
|
185
|
+
metadata: {}
|
200
186
|
post_install_message:
|
201
187
|
rdoc_options:
|
202
188
|
- --charset=UTF-8
|
203
189
|
require_paths:
|
204
190
|
- lib
|
205
191
|
required_ruby_version: !ruby/object:Gem::Requirement
|
206
|
-
none: false
|
207
192
|
requirements:
|
208
|
-
- -
|
193
|
+
- - '>='
|
209
194
|
- !ruby/object:Gem::Version
|
210
195
|
version: '0'
|
211
|
-
hash: -4004482261167388747
|
212
|
-
segments:
|
213
|
-
- 0
|
214
196
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
215
|
-
none: false
|
216
197
|
requirements:
|
217
|
-
- -
|
198
|
+
- - '>='
|
218
199
|
- !ruby/object:Gem::Version
|
219
200
|
version: '0'
|
220
|
-
hash: -4004482261167388747
|
221
|
-
segments:
|
222
|
-
- 0
|
223
201
|
requirements: []
|
224
202
|
rubyforge_project:
|
225
|
-
rubygems_version:
|
203
|
+
rubygems_version: 2.0.3
|
226
204
|
signing_key:
|
227
|
-
specification_version:
|
205
|
+
specification_version: 4
|
228
206
|
summary: CoffeeScript views in rails 3
|
229
207
|
test_files: []
|