js_rails_routes 0.10.0 → 0.10.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +19 -14
- data/LICENSE +1 -1
- data/README.md +5 -12
- data/js_rails_routes.gemspec +3 -3
- data/lib/js_rails_routes/language/typescript.rb +1 -1
- data/lib/js_rails_routes/version.rb +1 -1
- data/spec/js_rails_routes/language/typescript_spec.rb +1 -1
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c220670a9c5b41f33dee3409e91d9e385acdf085b6e960b3a7b0422ba95abca5
|
4
|
+
data.tar.gz: f62587c14af99d906788b5f5bf2b73ddfef49cf51683510b754752100e1b8b36
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f6dc1867c820eed26e1e5eac35c7b3f0fc02b0645e03d6503f752c0f9c9785f649aa3f67d8fe373b9aa8dad6769c18bda964a3947d76ed3ee0955ea96fb99b0e
|
7
|
+
data.tar.gz: 7f98004619d19fa90cdf988585925c25c7eb1e62550067fd8f7f7155a8c335b2738766ab86540b3632436e99c5c25d2ad77b826f86e6650554a2b4ab2dc95a15
|
data/CHANGELOG.md
CHANGED
@@ -6,6 +6,10 @@ This change log adheres to [keepachangelog.com](http://keepachangelog.com).
|
|
6
6
|
|
7
7
|
## [Unreleased]
|
8
8
|
|
9
|
+
## [0.10.1] - 2020-03-09
|
10
|
+
### Fixed
|
11
|
+
- Improved TypeScript typing
|
12
|
+
|
9
13
|
## [0.10.0] - 2018-10-29
|
10
14
|
### Added
|
11
15
|
- Enable to change route's name
|
@@ -74,17 +78,18 @@ This change log adheres to [keepachangelog.com](http://keepachangelog.com).
|
|
74
78
|
### Added
|
75
79
|
- Implement "js:rails:routes" task
|
76
80
|
|
77
|
-
[Unreleased]: https://github.com/
|
78
|
-
[0.10.
|
79
|
-
[0.
|
80
|
-
[0.
|
81
|
-
[0.8.
|
82
|
-
[0.
|
83
|
-
[0.7.
|
84
|
-
[0.
|
85
|
-
[0.
|
86
|
-
[0.
|
87
|
-
[0.
|
88
|
-
[0.
|
89
|
-
[0.2.
|
90
|
-
[0.
|
81
|
+
[Unreleased]: https://github.com/increments/js_rails_routes/compare/v0.10.1...HEAD
|
82
|
+
[0.10.1]: https://github.com/increments/js_rails_routes/compare/v0.10.0...v0.10.1
|
83
|
+
[0.10.0]: https://github.com/increments/js_rails_routes/compare/v0.9.0...v0.10.0
|
84
|
+
[0.9.0]: https://github.com/increments/js_rails_routes/compare/v0.8.1...v0.9.0
|
85
|
+
[0.8.1]: https://github.com/increments/js_rails_routes/compare/v0.8.0...v0.8.1
|
86
|
+
[0.8.0]: https://github.com/increments/js_rails_routes/compare/v0.7.1...v0.8.0
|
87
|
+
[0.7.1]: https://github.com/increments/js_rails_routes/compare/v0.7.0...v0.7.1
|
88
|
+
[0.7.0]: https://github.com/increments/js_rails_routes/compare/v0.6.0...v0.7.0
|
89
|
+
[0.6.0]: https://github.com/increments/js_rails_routes/compare/v0.5.0...v0.6.0
|
90
|
+
[0.5.0]: https://github.com/increments/js_rails_routes/compare/v0.4.0...v0.5.0
|
91
|
+
[0.4.0]: https://github.com/increments/js_rails_routes/compare/v0.3.0...v0.4.0
|
92
|
+
[0.3.0]: https://github.com/increments/js_rails_routes/compare/v0.2.1...v0.3.0
|
93
|
+
[0.2.1]: https://github.com/increments/js_rails_routes/compare/v0.2.0...v0.2.1
|
94
|
+
[0.2.0]: https://github.com/increments/js_rails_routes/compare/v0.1.0...v0.2.0
|
95
|
+
[0.1.0]: https://github.com/increments/js_rails_routes/compare/033b945...v0.1.0
|
data/LICENSE
CHANGED
data/README.md
CHANGED
@@ -1,11 +1,10 @@
|
|
1
1
|
# rake js:routes
|
2
2
|
|
3
3
|
[![Gem](https://img.shields.io/gem/v/js_rails_routes.svg?maxAge=2592000)](https://rubygems.org/gems/js_rails_routes)
|
4
|
-
[![Build Status](https://travis-ci.org/
|
5
|
-
[![Code Climate](https://codeclimate.com/github/
|
6
|
-
[![Test Coverage](https://codeclimate.com/github/
|
7
|
-
[![license](https://img.shields.io/github/license/
|
8
|
-
[![Analytics](https://ga-beacon.appspot.com/UA-4932407-14/js_rails_routes/readme)](https://github.com/igrigorik/ga-beacon)
|
4
|
+
[![Build Status](https://travis-ci.org/increments/js_rails_routes.svg?branch=master)](https://travis-ci.org/increments/js_rails_routes)
|
5
|
+
[![Code Climate](https://codeclimate.com/github/increments/js_rails_routes/badges/gpa.svg)](https://codeclimate.com/github/increments/js_rails_routes)
|
6
|
+
[![Test Coverage](https://codeclimate.com/github/increments/js_rails_routes/badges/coverage.svg)](https://codeclimate.com/github/increments/js_rails_routes/coverage)
|
7
|
+
[![license](https://img.shields.io/github/license/increments/js_rails_routes.svg?maxAge=2592000)](https://github.com/increments/js_rails_routes/blob/master/LICENSE)
|
9
8
|
|
10
9
|
Generate a ES6 module that contains Rails routes.
|
11
10
|
|
@@ -135,10 +134,4 @@ gem 'js_rails_routes', group: :development
|
|
135
134
|
|
136
135
|
## License
|
137
136
|
|
138
|
-
[MIT](https://github.com/
|
139
|
-
|
140
|
-
## Author
|
141
|
-
|
142
|
-
[mizchi](https://github.com/mizchi) wrote "js:routes" task with referencing [mtrpcic/js-routes](https://github.com/mtrpcic/js-routes).
|
143
|
-
|
144
|
-
[yuku-t](https://yuku-t.com) refactored and improved the mizchi's script and published to [rubygems](https://rubygems.org/gems/js_rails_routes).
|
137
|
+
[MIT](https://github.com/increments/js_rails_routes/blob/master/LICENSE)
|
data/js_rails_routes.gemspec
CHANGED
@@ -8,16 +8,16 @@ Gem::Specification.new do |spec|
|
|
8
8
|
spec.name = 'js_rails_routes'
|
9
9
|
spec.version = JSRailsRoutes::VERSION
|
10
10
|
spec.authors = ['Yuku Takahashi']
|
11
|
-
spec.email = ['
|
11
|
+
spec.email = ['yuku@qiita.com']
|
12
12
|
spec.summary = 'Generate a ES6 module that contains Rails routes.'
|
13
|
-
spec.homepage = 'https://github.com/
|
13
|
+
spec.homepage = 'https://github.com/increments/js_rails_routes'
|
14
14
|
spec.license = 'MIT'
|
15
15
|
spec.files = `git ls-files -z`.split("\x0")
|
16
16
|
spec.require_paths = ['lib']
|
17
17
|
spec.required_ruby_version = '>= 2.3.0'
|
18
18
|
|
19
19
|
spec.add_dependency 'rails', '>= 3.2'
|
20
|
-
spec.add_development_dependency 'bundler', '
|
20
|
+
spec.add_development_dependency 'bundler', '>= 1.16'
|
21
21
|
spec.add_development_dependency 'codeclimate-test-reporter', '~> 1.0'
|
22
22
|
spec.add_development_dependency 'rake', '~> 12.3'
|
23
23
|
spec.add_development_dependency 'rspec', '~> 3.8'
|
@@ -11,7 +11,7 @@ module JSRailsRoutes
|
|
11
11
|
type Params<Keys extends string> = { [key in Keys]: Value } & Record<string, Value>
|
12
12
|
function process(route: string, params: Record<string, Value> | undefined, keys: string[]): string {
|
13
13
|
if (!params) return route
|
14
|
-
var query = [];
|
14
|
+
var query: string[] = [];
|
15
15
|
for (var param in params) if (params.hasOwnProperty(param)) {
|
16
16
|
if (keys.indexOf(param) === -1) {
|
17
17
|
query.push(param + "=" + encodeURIComponent(params[param].toString()));
|
@@ -14,7 +14,7 @@ RSpec.describe JSRailsRoutes::Language::TypeScript do
|
|
14
14
|
type Params<Keys extends string> = { [key in Keys]: Value } & Record<string, Value>
|
15
15
|
function process(route: string, params: Record<string, Value> | undefined, keys: string[]): string {
|
16
16
|
if (!params) return route
|
17
|
-
var query = [];
|
17
|
+
var query: string[] = [];
|
18
18
|
for (var param in params) if (params.hasOwnProperty(param)) {
|
19
19
|
if (keys.indexOf(param) === -1) {
|
20
20
|
query.push(param + "=" + encodeURIComponent(params[param].toString()));
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: js_rails_routes
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.10.
|
4
|
+
version: 0.10.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yuku Takahashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-03-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -28,14 +28,14 @@ dependencies:
|
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '1.16'
|
34
34
|
type: :development
|
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.16'
|
41
41
|
- !ruby/object:Gem::Dependency
|
@@ -124,7 +124,7 @@ dependencies:
|
|
124
124
|
version: 0.16.1
|
125
125
|
description:
|
126
126
|
email:
|
127
|
-
-
|
127
|
+
- yuku@qiita.com
|
128
128
|
executables: []
|
129
129
|
extensions: []
|
130
130
|
extra_rdoc_files: []
|
@@ -166,7 +166,7 @@ files:
|
|
166
166
|
- spec/support/shared_contexts/run_in_a_sandbox.rb
|
167
167
|
- spec/support/test_app.rb
|
168
168
|
- spec/tmp/.keep
|
169
|
-
homepage: https://github.com/
|
169
|
+
homepage: https://github.com/increments/js_rails_routes
|
170
170
|
licenses:
|
171
171
|
- MIT
|
172
172
|
metadata: {}
|
@@ -185,8 +185,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
185
|
- !ruby/object:Gem::Version
|
186
186
|
version: '0'
|
187
187
|
requirements: []
|
188
|
-
|
189
|
-
rubygems_version: 2.7.6
|
188
|
+
rubygems_version: 3.0.3
|
190
189
|
signing_key:
|
191
190
|
specification_version: 4
|
192
191
|
summary: Generate a ES6 module that contains Rails routes.
|