web_pipe 0.10.0 → 0.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: eb774cbbdd90831e9ffcd5dba76265c37585b65f56618aff8cfa311b78d2bea8
4
- data.tar.gz: c456b68f6995308a740dacf97bb7177f140c51757fa6f680ecc7e515036d37a0
3
+ metadata.gz: 0b9528f537d4932f676d0ff5db2489581b9c6371d4b134a9d455b77bca14afa6
4
+ data.tar.gz: 853e2302ac6f3a40e91e17164512a2d6c2e4b4ed28ab3cdf06b76c957f822548
5
5
  SHA512:
6
- metadata.gz: 118d6af2b98c082fa174b33e092744d82a5e2667e20bc717ef996fa9da1b934d44a618331527d2c328d02ce2ea0dc62b3649800f326cfc7516f9ba3ba23c8797
7
- data.tar.gz: 32cb91bec0de9aaab6f48d48f4c68334a64fc3c5e944be4f6c20fccaacf1dab928b59809b0e50c129306d43951f0ef028812ab6196503cfff1d830cf8b5e658a
6
+ metadata.gz: 7396370ab3323bd7e62ef6439b1611e9c53d1d8481f8f882b8463c03d40d734c47085554e81b9225b1c65e02f39629a4dfcb1bb0358e95c53fe7a23f15015c1a
7
+ data.tar.gz: a6a58fd2c768d8e3b438dc7e7c16009961a782f9a8b7ab8eae57644628b827cf333da0fb151d7a43402cb6feed99e426df1b0d1c42696392d58ebc79a7e2b132
data/CHANGELOG.md CHANGED
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](http://keepachangelog.com/)
5
5
  and this project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
+ ## [0.11.0] - 2019-12-28
8
+ ### Added
9
+ - **BREAKING**. `dry-transformer` (former `transproc`) dependency is now
10
+ optional.
11
+ [[#37]](https://github.com/waiting-for-dev/web_pipe/pull/37)
12
+ - Switch `transproc` dependency to `dry-transformer`.
13
+ [[#37]](https://github.com/waiting-for-dev/web_pipe/pull/37)
14
+
7
15
  ## [0.10.0] - 2019-11-15
8
16
  ### Added
9
17
  - `:rails` extension integrating with Ruby On Rails.
data/README.md CHANGED
@@ -92,10 +92,9 @@ run HelloApp.new
92
92
 
93
93
  ## Current status
94
94
 
95
- `web_pipe` is in active development. The very basic features to build
96
- a rack application are all available. However, very necessary
97
- conveniences to build a production application, for example a session
98
- mechanism, are still missing.
95
+ `web_pipe` is in active development but ready to be used in any environment.
96
+ Common needs are covered and while you can expect some API changes, they won't
97
+ be very important and everything will be properly documented.
99
98
 
100
99
  ## Contributing
101
100
 
@@ -36,7 +36,7 @@ option that will play specially well here is
36
36
  itself easily with Rails. Furthermore, we have a tailored `dry_view`
37
37
  [extension](https://waiting-for-dev.github.io/web_pipe/docs/extensions/dry_view.html).
38
38
 
39
- You need to use this extension if:
39
+ You need to use `:rails` extension if:
40
40
 
41
41
  - You want to use `action_view` as rendering system.
42
42
  - You want to use rails url helpers from your `WebPipe` application.
@@ -50,7 +50,6 @@ some behaviour for the view layer:
50
50
 
51
51
  - Which layout is applied to the template.
52
52
  - Which helpers will become available to the templates.
53
- - Where within `app/views/` templates are looked up.
54
53
 
55
54
  By default, the controller in use is `ActionController::Base`, which means that
56
55
  no layout is applied and only built-in helpers (for example,
@@ -95,7 +94,9 @@ end
95
94
 
96
95
  Notice that we used the keyword `template:` instead of taking advantage of
97
96
  automatic template lookup. We did that way so that we don't have to create also
98
- an `ArticlesController`, but it's up to you.
97
+ an `ArticlesController`, but it's up to you. In the case of having an
98
+ `ArticlesController` we could just do `conn.render(:index, assigns: {
99
+ articles: Article.all })`.
99
100
 
100
101
  Besides, this extension provides with two other methods:
101
102
 
@@ -1,13 +1,13 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'transproc'
3
+ require 'dry/transformer'
4
4
 
5
5
  module WebPipe
6
6
  module Params
7
7
  module Transf
8
- extend Transproc::Registry
8
+ extend Dry::Transformer::Registry
9
9
 
10
- import Transproc::HashTransformations
10
+ import Dry::Transformer::HashTransformations
11
11
 
12
12
  def self.id(params)
13
13
  params
@@ -14,9 +14,9 @@ module WebPipe
14
14
  # # http://www.example.com?foo=bar
15
15
  # conn.params #=> { 'foo' => 'bar' }
16
16
  #
17
- # Further processing can be specified thanks to `transproc` gem (you
17
+ # Further processing can be specified thanks to `dry-transformer` gem (you
18
18
  # need to add it yourself to the Gemfile). All hash transformations
19
- # in `transproc` are available:
19
+ # in `dry-transformer` are available:
20
20
  #
21
21
  # @example
22
22
  # # http://www.example.com?foo=bar
@@ -65,7 +65,7 @@ module WebPipe
65
65
  # conn.
66
66
  # params(fake) #=> { fake: :params }
67
67
  #
68
- # @see https://github.com/solnic/transproc
68
+ # @see https://github.com/dry-rb/dry-transformer
69
69
  module Params
70
70
  # Key where configured transformations are set
71
71
  PARAM_TRANSFORMATION_KEY = :param_transformations
@@ -40,7 +40,7 @@ module WebPipe
40
40
  # itself easily with Rails. Furthermore, we have a tailored `dry_view`
41
41
  # extension.
42
42
  #
43
- # You need to use this extension if:
43
+ # You need to use `:rails` extension if:
44
44
  #
45
45
  # - You want to use `action_view` as rendering system.
46
46
  # - You want to use rails url helpers from your {WebPipe} application.
@@ -54,7 +54,6 @@ module WebPipe
54
54
  #
55
55
  # - Which layout is applied to the template.
56
56
  # - Which helpers will become available to the templates.
57
- # - Where within `app/views/` templates are looked up.
58
57
  #
59
58
  # By default, the controller in use is `ActionController::Base`, which means
60
59
  # that no layout is applied and only built-in helpers (for example,
@@ -99,7 +98,9 @@ module WebPipe
99
98
  #
100
99
  # Notice that we used the keyword `template:` instead of taking advantage of
101
100
  # automatic template lookup. We did that way so that we don't have to create
102
- # also an `ArticlesController`, but it's up to you.
101
+ # also an `ArticlesController`, but it's up to you. In the case of having an
102
+ # `ArticlesController` we could just do `conn.render(:index, assigns: {
103
+ # articles: Article.all })`.
103
104
  #
104
105
  # Besides, this extension provides with two other methods:
105
106
  #
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module WebPipe
4
- VERSION = '0.10.0'
4
+ VERSION = '0.11.0'
5
5
  end
data/web_pipe.gemspec CHANGED
@@ -39,10 +39,10 @@ Gem::Specification.new do |spec|
39
39
  spec.add_runtime_dependency 'dry-struct', '~> 1.0'
40
40
  spec.add_runtime_dependency 'dry-types', '~> 1.1'
41
41
  spec.add_runtime_dependency 'rack', '~> 2.0'
42
- spec.add_runtime_dependency 'transproc', '~> 1.1'
43
42
 
44
- spec.add_development_dependency 'bundler', '~> 1.17'
43
+ spec.add_development_dependency 'bundler'
45
44
  spec.add_development_dependency 'dry-schema', '~> 1.0'
45
+ spec.add_development_dependency 'dry-transformer', '~> 0.1'
46
46
  spec.add_development_dependency 'dry-view', '~> 0.7'
47
47
  spec.add_development_dependency 'pry-byebug'
48
48
  spec.add_development_dependency 'rack-flash3', '~> 1.0'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: web_pipe
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marc Busqué
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-11-15 00:00:00.000000000 Z
11
+ date: 1970-01-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-monads
@@ -67,47 +67,47 @@ dependencies:
67
67
  - !ruby/object:Gem::Version
68
68
  version: '2.0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: transproc
70
+ name: bundler
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - "~>"
73
+ - - ">="
74
74
  - !ruby/object:Gem::Version
75
- version: '1.1'
76
- type: :runtime
75
+ version: '0'
76
+ type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - "~>"
80
+ - - ">="
81
81
  - !ruby/object:Gem::Version
82
- version: '1.1'
82
+ version: '0'
83
83
  - !ruby/object:Gem::Dependency
84
- name: bundler
84
+ name: dry-schema
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: '1.17'
89
+ version: '1.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
- version: '1.17'
96
+ version: '1.0'
97
97
  - !ruby/object:Gem::Dependency
98
- name: dry-schema
98
+ name: dry-transformer
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '1.0'
103
+ version: '0.1'
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: '1.0'
110
+ version: '0.1'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: dry-view
113
113
  requirement: !ruby/object:Gem::Requirement
@@ -335,8 +335,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
335
335
  - !ruby/object:Gem::Version
336
336
  version: '0'
337
337
  requirements: []
338
- rubyforge_project:
339
- rubygems_version: 2.7.8
338
+ rubygems_version: 3.0.6
340
339
  signing_key:
341
340
  specification_version: 4
342
341
  summary: Rack application builder through a pipe of operations on an immutable struct.