js-routes 1.4.1 → 1.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +17 -18
- data/Appraisals +15 -8
- data/CHANGELOG.md +4 -0
- data/Readme.md +5 -0
- data/gemfiles/{rails40.gemfile → rails40_sprockets_2.gemfile} +1 -1
- data/gemfiles/{rails40_sprockets3.gemfile → rails40_sprockets_3.gemfile} +0 -0
- data/gemfiles/{rails41.gemfile → rails41_sprockets_2.gemfile} +1 -1
- data/gemfiles/{rails41_sprockets3.gemfile → rails41_sprockets_3.gemfile} +0 -0
- data/gemfiles/{rails42.gemfile → rails42_sprockets_2.gemfile} +2 -2
- data/gemfiles/{rails42_sprockets3.gemfile → rails42_sprockets_3.gemfile} +1 -1
- data/gemfiles/{rails50_sprockets3.gemfile → rails50_sprockets_3.gemfile} +1 -1
- data/gemfiles/rails51_sprockets_3.gemfile +8 -0
- data/lib/js_routes/engine.rb +5 -3
- data/lib/js_routes/version.rb +1 -1
- data/spec/js_routes/rails_routes_compatibility_spec.rb +0 -3
- metadata +11 -11
- data/gemfiles/rails50.gemfile +0 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7f2b764ad8b2e830d272dae6c27c5d5ffd7d62ff
|
4
|
+
data.tar.gz: 0919ef9b1b2b835badcfc149ef2c98b5e9cff8f4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 91aec6308159d5b88096a57ab461bd0f5db939778d3deffc915f846da1deb17e3506837119f8f77eab6d21270f50167da9809ebf6b9183357b7a666fd6bda523
|
7
|
+
data.tar.gz: 0492743727d0493de6ea1480255659f7cd53efcd289d3a4c78e9d1781c95123afe700d57bb2acda76f6f953a60b5580ae3b65944e4b05e3d08837f2659123aca
|
data/.travis.yml
CHANGED
@@ -16,14 +16,14 @@ rvm:
|
|
16
16
|
|
17
17
|
gemfile:
|
18
18
|
- gemfiles/rails32.gemfile
|
19
|
-
- gemfiles/
|
20
|
-
- gemfiles/
|
21
|
-
- gemfiles/
|
22
|
-
- gemfiles/
|
23
|
-
- gemfiles/
|
24
|
-
- gemfiles/
|
25
|
-
- gemfiles/
|
26
|
-
- gemfiles/
|
19
|
+
- gemfiles/rails40_sprockets_2.gemfile
|
20
|
+
- gemfiles/rails40_sprockets_3.gemfile
|
21
|
+
- gemfiles/rails41_sprockets_2.gemfile
|
22
|
+
- gemfiles/rails41_sprockets_3.gemfile
|
23
|
+
- gemfiles/rails42_sprockets_2.gemfile
|
24
|
+
- gemfiles/rails42_sprockets_3.gemfile
|
25
|
+
- gemfiles/rails50_sprockets_3.gemfile
|
26
|
+
- gemfiles/rails51_sprockets_3.gemfile
|
27
27
|
|
28
28
|
sudo: false
|
29
29
|
|
@@ -40,21 +40,20 @@ matrix:
|
|
40
40
|
- rvm: jruby-19mode
|
41
41
|
- rvm: ruby-head
|
42
42
|
- rvm: jruby-head
|
43
|
-
- gemfile: gemfiles/rails50.gemfile
|
44
43
|
exclude:
|
45
44
|
- rvm: 2.0
|
46
|
-
gemfile: gemfiles/
|
47
|
-
- rvm: 2.0
|
48
|
-
gemfile: gemfiles/rails50_sprockets3.gemfile
|
45
|
+
gemfile: gemfiles/rails50_sprockets_3.gemfile
|
49
46
|
- rvm: 2.1
|
50
|
-
gemfile: gemfiles/
|
47
|
+
gemfile: gemfiles/rails50_sprockets_3.gemfile
|
48
|
+
- rvm: 2.0
|
49
|
+
gemfile: gemfiles/rails51_sprockets_3.gemfile
|
51
50
|
- rvm: 2.1
|
52
|
-
gemfile: gemfiles/
|
51
|
+
gemfile: gemfiles/rails51_sprockets_3.gemfile
|
53
52
|
- rvm: 2.4.1
|
54
|
-
gemfile: gemfiles/
|
53
|
+
gemfile: gemfiles/rails40_sprockets_2.gemfile # Segmentation fault (core dumped) for 2.4
|
55
54
|
- rvm: 2.4.1
|
56
|
-
gemfile: gemfiles/
|
55
|
+
gemfile: gemfiles/rails40_sprockets_3.gemfile # Segmentation fault (core dumped) for 2.4
|
57
56
|
- rvm: 2.4.1
|
58
|
-
gemfile: gemfiles/
|
57
|
+
gemfile: gemfiles/rails41_sprockets_2.gemfile # Segmentation fault (core dumped) for 2.4
|
59
58
|
- rvm: 2.4.1
|
60
|
-
gemfile: gemfiles/
|
59
|
+
gemfile: gemfiles/rails41_sprockets_3.gemfile # Segmentation fault (core dumped) for 2.4
|
data/Appraisals
CHANGED
@@ -3,14 +3,21 @@ appraise "rails32" do
|
|
3
3
|
gem 'tzinfo'
|
4
4
|
end
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
6
|
+
def define_appraisal(rails, version, sprockets)
|
7
|
+
sprockets.each do |sprocket|
|
8
|
+
appraise "#{rails}-sprockets-#{sprocket}" do
|
9
|
+
gem "railties", "~> #{version}"
|
10
|
+
gem "sprockets", "~> #{sprocket}.0"
|
11
|
+
end
|
10
12
|
end
|
13
|
+
end
|
11
14
|
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
15
|
+
[
|
16
|
+
[:rails40, '4.0.13', [2, 3]],
|
17
|
+
[:rails41, '4.1.16', [2, 3]],
|
18
|
+
[:rails42, '4.2.9', [2, 3]],
|
19
|
+
[:rails50, '5.0.5', [3]],
|
20
|
+
[:rails51, '5.1.3', [3]]
|
21
|
+
].each do |name, version, sprockets|
|
22
|
+
define_appraisal(name, version, sprockets)
|
16
23
|
end
|
data/CHANGELOG.md
CHANGED
data/Readme.md
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
# JsRoutes
|
2
2
|
[![Build Status](https://travis-ci.org/railsware/js-routes.svg?branch=master)](https://travis-ci.org/railsware/js-routes)
|
3
|
+
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Frailsware%2Fjs-routes.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Frailsware%2Fjs-routes?ref=badge_shield)
|
3
4
|
|
4
5
|
Generates javascript file that defines all Rails named routes as javascript helpers
|
5
6
|
|
@@ -244,3 +245,7 @@ Advantages of this one are:
|
|
244
245
|
#### Thanks to [Contributors](https://github.com/railsware/js-routes/contributors)
|
245
246
|
|
246
247
|
#### Have fun
|
248
|
+
|
249
|
+
|
250
|
+
## License
|
251
|
+
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Frailsware%2Fjs-routes.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Frailsware%2Fjs-routes?ref=badge_large)
|
File without changes
|
File without changes
|
data/lib/js_routes/engine.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
|
-
class
|
1
|
+
class JsRoutes
|
2
|
+
class SprocketsExtension
|
2
3
|
def initialize(filename, &block)
|
3
4
|
@filename = filename
|
4
5
|
@source = block.call
|
@@ -55,14 +56,14 @@ class Engine < ::Rails::Engine
|
|
55
56
|
if is_running_rails_32
|
56
57
|
Rails.application.assets.register_preprocessor(
|
57
58
|
"application/javascript",
|
58
|
-
|
59
|
+
SprocketsExtension,
|
59
60
|
)
|
60
61
|
else
|
61
62
|
# Other rails version, assumed newer
|
62
63
|
Rails.application.config.assets.configure do |config|
|
63
64
|
config.register_preprocessor(
|
64
65
|
"application/javascript",
|
65
|
-
|
66
|
+
SprocketsExtension,
|
66
67
|
)
|
67
68
|
end
|
68
69
|
end
|
@@ -71,3 +72,4 @@ class Engine < ::Rails::Engine
|
|
71
72
|
end
|
72
73
|
end
|
73
74
|
end
|
75
|
+
end
|
data/lib/js_routes/version.rb
CHANGED
@@ -332,9 +332,6 @@ describe JsRoutes, "compatibility with Rails" do
|
|
332
332
|
expect(evaljs("Routes.inbox_message_path(5, {id: 7, q: 'hello', _options: true})")).to eq(test_routes.inbox_message_path(5, id: 7, q: 'hello'))
|
333
333
|
end
|
334
334
|
|
335
|
-
it "should check for options special key" do
|
336
|
-
end
|
337
|
-
|
338
335
|
it "should support 0 as an id option" do
|
339
336
|
expect(evaljs("Routes.inbox_path({id: 0})")).to eq(test_routes.inbox_path(0))
|
340
337
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: js-routes
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bogdan Gusiev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-11-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -156,14 +156,14 @@ files:
|
|
156
156
|
- Readme.md
|
157
157
|
- app/assets/javascripts/js-routes.js.erb
|
158
158
|
- gemfiles/rails32.gemfile
|
159
|
-
- gemfiles/
|
160
|
-
- gemfiles/
|
161
|
-
- gemfiles/
|
162
|
-
- gemfiles/
|
163
|
-
- gemfiles/
|
164
|
-
- gemfiles/
|
165
|
-
- gemfiles/
|
166
|
-
- gemfiles/
|
159
|
+
- gemfiles/rails40_sprockets_2.gemfile
|
160
|
+
- gemfiles/rails40_sprockets_3.gemfile
|
161
|
+
- gemfiles/rails41_sprockets_2.gemfile
|
162
|
+
- gemfiles/rails41_sprockets_3.gemfile
|
163
|
+
- gemfiles/rails42_sprockets_2.gemfile
|
164
|
+
- gemfiles/rails42_sprockets_3.gemfile
|
165
|
+
- gemfiles/rails50_sprockets_3.gemfile
|
166
|
+
- gemfiles/rails51_sprockets_3.gemfile
|
167
167
|
- js-routes.gemspec
|
168
168
|
- lib/js-routes.rb
|
169
169
|
- lib/js_routes.rb
|
@@ -202,7 +202,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
202
202
|
version: '0'
|
203
203
|
requirements: []
|
204
204
|
rubyforge_project:
|
205
|
-
rubygems_version: 2.6.
|
205
|
+
rubygems_version: 2.6.7
|
206
206
|
signing_key:
|
207
207
|
specification_version: 4
|
208
208
|
summary: Brings Rails named routes to javascript
|