dry-view 0.7.0 → 0.8.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 +4 -4
- data/CHANGELOG.md +88 -54
- data/LICENSE +20 -0
- data/README.md +13 -37
- data/dry-view.gemspec +24 -14
- data/lib/dry/view/context.rb +3 -3
- data/lib/dry/view/decorated_attributes.rb +2 -1
- data/lib/dry/view/errors.rb +3 -1
- data/lib/dry/view/exposure.rb +22 -16
- data/lib/dry/view/exposures.rb +4 -3
- data/lib/dry/view/part.rb +12 -6
- data/lib/dry/view/part_builder.rb +6 -4
- data/lib/dry/view/path.rb +1 -1
- data/lib/dry/view/render_environment.rb +4 -4
- data/lib/dry/view/render_environment_missing.rb +4 -4
- data/lib/dry/view/rendered.rb +1 -1
- data/lib/dry/view/renderer.rb +1 -1
- data/lib/dry/view/scope.rb +21 -7
- data/lib/dry/view/scope_builder.rb +4 -4
- data/lib/dry/view/tilt/erb.rb +1 -1
- data/lib/dry/view/tilt/erbse.rb +1 -1
- data/lib/dry/view/tilt/haml.rb +3 -3
- data/lib/dry/view/tilt.rb +1 -1
- data/lib/dry/view/version.rb +1 -1
- data/lib/dry/view.rb +27 -20
- metadata +46 -47
- data/.codeclimate.yml +0 -18
- data/.gitignore +0 -26
- data/.rspec +0 -2
- data/.travis.yml +0 -28
- data/.yardopts +0 -5
- data/CONTRIBUTING.md +0 -29
- data/Gemfile +0 -32
- data/LICENSE.md +0 -10
- data/Rakefile +0 -6
- data/bin/console +0 -7
- data/bin/setup +0 -5
- data/bin/setup_helpers.rb +0 -27
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require "dry/core/cache"
|
4
|
-
require "dry/equalizer"
|
4
|
+
require "dry/core/equalizer"
|
5
5
|
require_relative "part"
|
6
6
|
|
7
7
|
module Dry
|
@@ -54,7 +54,7 @@ module Dry
|
|
54
54
|
klass.new(
|
55
55
|
name: name,
|
56
56
|
value: value,
|
57
|
-
render_env: render_env
|
57
|
+
render_env: render_env
|
58
58
|
)
|
59
59
|
end
|
60
60
|
|
@@ -69,11 +69,13 @@ module Dry
|
|
69
69
|
build_part(name, arr, **options.merge(as: collection_as))
|
70
70
|
end
|
71
71
|
|
72
|
+
# rubocop:disable Lint/UnusedMethodArgument
|
72
73
|
def collection_options(name:, **options)
|
73
74
|
collection_as = options[:as].is_a?(Array) ? options[:as].first : nil
|
74
75
|
|
75
76
|
options.merge(as: collection_as)
|
76
77
|
end
|
78
|
+
# rubocop:enable Lint/UnusedMethodArgument
|
77
79
|
|
78
80
|
def collection_item_options(name:, **options)
|
79
81
|
singular_name = inflector.singularize(name).to_sym
|
@@ -90,7 +92,7 @@ module Dry
|
|
90
92
|
|
91
93
|
options.merge(
|
92
94
|
name: singular_name,
|
93
|
-
as: singular_as
|
95
|
+
as: singular_as
|
94
96
|
)
|
95
97
|
end
|
96
98
|
|
@@ -114,7 +116,7 @@ module Dry
|
|
114
116
|
# Give autoloaders a chance to act
|
115
117
|
begin
|
116
118
|
klass = namespace.const_get(name)
|
117
|
-
rescue NameError
|
119
|
+
rescue NameError # rubocop:disable Lint/SuppressedException
|
118
120
|
end
|
119
121
|
|
120
122
|
if !klass && namespace.const_defined?(name, false)
|
data/lib/dry/view/path.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require "dry/equalizer"
|
3
|
+
require "dry/core/equalizer"
|
4
4
|
|
5
5
|
module Dry
|
6
6
|
class View
|
@@ -12,7 +12,7 @@ module Dry
|
|
12
12
|
inflector: config.inflector,
|
13
13
|
context: context,
|
14
14
|
scope_builder: config.scope_builder.new(namespace: config.scope_namespace),
|
15
|
-
part_builder: config.part_builder.new(namespace: config.part_namespace)
|
15
|
+
part_builder: config.part_builder.new(namespace: config.part_namespace)
|
16
16
|
)
|
17
17
|
end
|
18
18
|
|
@@ -36,7 +36,7 @@ module Dry
|
|
36
36
|
part_builder.(name, value, **options)
|
37
37
|
end
|
38
38
|
|
39
|
-
def scope(name = nil, locals)
|
39
|
+
def scope(name = nil, locals) # rubocop:disable Style/OptionalArguments
|
40
40
|
scope_builder.(name, locals)
|
41
41
|
end
|
42
42
|
|
@@ -54,7 +54,7 @@ module Dry
|
|
54
54
|
inflector: inflector,
|
55
55
|
context: context,
|
56
56
|
scope_builder: scope_builder,
|
57
|
-
part_builder: part_builder
|
57
|
+
part_builder: part_builder
|
58
58
|
)
|
59
59
|
end
|
60
60
|
end
|
@@ -20,19 +20,19 @@ module Dry
|
|
20
20
|
raise MissingEnvironmentError
|
21
21
|
end
|
22
22
|
|
23
|
-
def part(
|
23
|
+
def part(_name, _value, **_options)
|
24
24
|
raise MissingEnvironmentError
|
25
25
|
end
|
26
26
|
|
27
|
-
def scope(
|
27
|
+
def scope(_name = nil, _locals) # rubocop:disable Style/OptionalArguments
|
28
28
|
raise MissingEnvironmentError
|
29
29
|
end
|
30
30
|
|
31
|
-
def template(
|
31
|
+
def template(_name, _scope)
|
32
32
|
raise MissingEnvironmentError
|
33
33
|
end
|
34
34
|
|
35
|
-
def partial(
|
35
|
+
def partial(_name, _scope)
|
36
36
|
raise MissingEnvironmentError
|
37
37
|
end
|
38
38
|
|
data/lib/dry/view/rendered.rb
CHANGED
data/lib/dry/view/renderer.rb
CHANGED
data/lib/dry/view/scope.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require "dry/equalizer"
|
3
|
+
require "dry/core/equalizer"
|
4
4
|
require "dry/core/constants"
|
5
5
|
require_relative "render_environment_missing"
|
6
6
|
|
@@ -59,7 +59,11 @@ module Dry
|
|
59
59
|
# @return [Scope]
|
60
60
|
#
|
61
61
|
# @api public
|
62
|
-
def initialize(
|
62
|
+
def initialize(
|
63
|
+
name: nil,
|
64
|
+
locals: Dry::Core::Constants::EMPTY_HASH,
|
65
|
+
render_env: RenderEnvironmentMissing.new
|
66
|
+
)
|
63
67
|
@_name = name
|
64
68
|
@_locals = locals
|
65
69
|
@_render_env = render_env
|
@@ -83,10 +87,16 @@ module Dry
|
|
83
87
|
# @api public
|
84
88
|
def render(partial_name = nil, **locals, &block)
|
85
89
|
partial_name ||= _name
|
86
|
-
raise ArgumentError, "+partial_name+ must be provided for unnamed scopes" unless partial_name
|
87
|
-
partial_name = _inflector.underscore(_inflector.demodulize(partial_name.to_s)) if partial_name.is_a?(Class)
|
88
90
|
|
89
|
-
|
91
|
+
unless partial_name
|
92
|
+
raise ArgumentError, "+partial_name+ must be provided for unnamed scopes"
|
93
|
+
end
|
94
|
+
|
95
|
+
if partial_name.is_a?(Class)
|
96
|
+
partial_name = _inflector.underscore(_inflector.demodulize(partial_name.to_s))
|
97
|
+
end
|
98
|
+
|
99
|
+
_render_env.partial(partial_name, _render_scope(**locals), &block)
|
90
100
|
end
|
91
101
|
|
92
102
|
# Build a new scope using a scope class matching the provided name
|
@@ -150,9 +160,13 @@ module Dry
|
|
150
160
|
super
|
151
161
|
end
|
152
162
|
end
|
163
|
+
ruby2_keywords(:method_missing) if respond_to?(:ruby2_keywords, true)
|
153
164
|
|
154
165
|
def respond_to_missing?(name, include_private = false)
|
155
|
-
_locals.key?(name) ||
|
166
|
+
_locals.key?(name) ||
|
167
|
+
_render_env.context.respond_to?(name) ||
|
168
|
+
CONVENIENCE_METHODS.include?(name) ||
|
169
|
+
super
|
156
170
|
end
|
157
171
|
|
158
172
|
def _render_scope(**locals)
|
@@ -162,7 +176,7 @@ module Dry
|
|
162
176
|
self.class.new(
|
163
177
|
# FIXME: what about `name`?
|
164
178
|
locals: locals,
|
165
|
-
render_env: _render_env
|
179
|
+
render_env: _render_env
|
166
180
|
)
|
167
181
|
end
|
168
182
|
end
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require "dry/core/cache"
|
4
|
-
require "dry/equalizer"
|
4
|
+
require "dry/core/equalizer"
|
5
5
|
require_relative "scope"
|
6
6
|
|
7
7
|
module Dry
|
@@ -46,11 +46,11 @@ module Dry
|
|
46
46
|
# @return [Dry::View::Scope]
|
47
47
|
#
|
48
48
|
# @api private
|
49
|
-
def call(name = nil, locals)
|
49
|
+
def call(name = nil, locals) # rubocop:disable Style/OptionalArguments
|
50
50
|
scope_class(name).new(
|
51
51
|
name: name,
|
52
52
|
locals: locals,
|
53
|
-
render_env: render_env
|
53
|
+
render_env: render_env
|
54
54
|
)
|
55
55
|
end
|
56
56
|
|
@@ -76,7 +76,7 @@ module Dry
|
|
76
76
|
# Give autoloaders a chance to act
|
77
77
|
begin
|
78
78
|
klass = namespace.const_get(name)
|
79
|
-
rescue NameError
|
79
|
+
rescue NameError # rubocop:disable Lint/SuppressedException
|
80
80
|
end
|
81
81
|
|
82
82
|
if !klass && namespace.const_defined?(name, false)
|
data/lib/dry/view/tilt/erb.rb
CHANGED
data/lib/dry/view/tilt/erbse.rb
CHANGED
data/lib/dry/view/tilt/haml.rb
CHANGED
@@ -5,8 +5,8 @@ module Dry
|
|
5
5
|
module Tilt
|
6
6
|
module Haml
|
7
7
|
def self.requirements
|
8
|
-
["hamlit
|
9
|
-
dry-view requires hamlit
|
8
|
+
["hamlit", <<~ERROR]
|
9
|
+
dry-view requires hamlit (3.0 or greater) for full compatibility when rendering .haml templates (e.g. implicitly capturing block content when yielding)
|
10
10
|
|
11
11
|
To ignore this and use another engine for .haml templates, dereigster this adapter before calling your views:
|
12
12
|
|
@@ -15,7 +15,7 @@ module Dry
|
|
15
15
|
end
|
16
16
|
|
17
17
|
def self.activate
|
18
|
-
# Requiring hamlit
|
18
|
+
# Requiring hamlit will register the engine with Tilt
|
19
19
|
self
|
20
20
|
end
|
21
21
|
end
|
data/lib/dry/view/tilt.rb
CHANGED
data/lib/dry/view/version.rb
CHANGED
data/lib/dry/view.rb
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
require "dry/configurable"
|
4
4
|
require "dry/core/cache"
|
5
|
-
require "dry/equalizer"
|
5
|
+
require "dry/core/equalizer"
|
6
6
|
require "dry/inflector"
|
7
7
|
|
8
8
|
require_relative "view/context"
|
@@ -58,7 +58,7 @@ module Dry
|
|
58
58
|
#
|
59
59
|
# @api public
|
60
60
|
# @!scope class
|
61
|
-
setting :paths
|
61
|
+
setting :paths, constructor: -> paths do
|
62
62
|
Array(paths).map { |path| Path[path] }
|
63
63
|
end
|
64
64
|
|
@@ -83,7 +83,7 @@ module Dry
|
|
83
83
|
# @param name [String, FalseClass, nil] layout name, or false to indicate no layout
|
84
84
|
# @api public
|
85
85
|
# @!scope class
|
86
|
-
setting :layout, false
|
86
|
+
setting :layout, default: false
|
87
87
|
|
88
88
|
# @overload config.layouts_dir=(dir)
|
89
89
|
# Set the name of the directory (within the configured `paths`) holding
|
@@ -92,7 +92,7 @@ module Dry
|
|
92
92
|
# @param dir [String] directory name
|
93
93
|
# @api public
|
94
94
|
# @!scope class
|
95
|
-
setting :layouts_dir, "layouts"
|
95
|
+
setting :layouts_dir, default: "layouts"
|
96
96
|
|
97
97
|
# @overload config.scope=(scope_class)
|
98
98
|
# Set the scope class to use when rendering the view's template.
|
@@ -118,7 +118,7 @@ module Dry
|
|
118
118
|
# @param context [Dry::View::Context] context object
|
119
119
|
# @api public
|
120
120
|
# @!scope class
|
121
|
-
setting :default_context, Context.new.freeze
|
121
|
+
setting :default_context, default: Context.new.freeze
|
122
122
|
|
123
123
|
# @overload config.default_format=(format)
|
124
124
|
# Set the default format to use when rendering.
|
@@ -128,7 +128,7 @@ module Dry
|
|
128
128
|
# @param format [Symbol]
|
129
129
|
# @api public
|
130
130
|
# @!scope class
|
131
|
-
setting :default_format, :html
|
131
|
+
setting :default_format, default: :html
|
132
132
|
|
133
133
|
# @overload config.scope_namespace=(namespace)
|
134
134
|
# Set a namespace that will be searched when building scope classes.
|
@@ -149,7 +149,7 @@ module Dry
|
|
149
149
|
# @param part_builder [Class]
|
150
150
|
# @api public
|
151
151
|
# @!scope class
|
152
|
-
setting :part_builder, PartBuilder
|
152
|
+
setting :part_builder, default: PartBuilder
|
153
153
|
|
154
154
|
# @overload config.scope_namespace=(namespace)
|
155
155
|
# Set a namespace that will be searched when building scope classes.
|
@@ -170,7 +170,7 @@ module Dry
|
|
170
170
|
# @param scope_builder [Class]
|
171
171
|
# @api public
|
172
172
|
# @!scope class
|
173
|
-
setting :scope_builder, ScopeBuilder
|
173
|
+
setting :scope_builder, default: ScopeBuilder
|
174
174
|
|
175
175
|
# @overload config.inflector=(inflector)
|
176
176
|
# Set an inflector to provide to the part_builder and scope_builder.
|
@@ -180,7 +180,7 @@ module Dry
|
|
180
180
|
# @param inflector
|
181
181
|
# @api public
|
182
182
|
# @!scope class
|
183
|
-
setting :inflector, Dry::Inflector.new
|
183
|
+
setting :inflector, default: Dry::Inflector.new
|
184
184
|
|
185
185
|
# @overload config.renderer_options=(options)
|
186
186
|
# A hash of options to pass to the template engine. Template engines are
|
@@ -195,7 +195,7 @@ module Dry
|
|
195
195
|
# @param options [Hash] renderer options
|
196
196
|
# @api public
|
197
197
|
# @!scope class
|
198
|
-
setting :renderer_options, DEFAULT_RENDERER_OPTIONS
|
198
|
+
setting :renderer_options, default: DEFAULT_RENDERER_OPTIONS, constructor: -> options do
|
199
199
|
DEFAULT_RENDERER_OPTIONS.merge(options.to_h).freeze
|
200
200
|
end
|
201
201
|
|
@@ -230,8 +230,10 @@ module Dry
|
|
230
230
|
# @!macro [new] exposure_options
|
231
231
|
# @param options [Hash] the exposure's options
|
232
232
|
# @option options [Boolean] :layout expose this value to the layout (defaults to false)
|
233
|
-
# @option options [Boolean] :decorate decorate this value in a matching Part (defaults to
|
234
|
-
#
|
233
|
+
# @option options [Boolean] :decorate decorate this value in a matching Part (defaults to
|
234
|
+
# true)
|
235
|
+
# @option options [Symbol, Class] :as an alternative name or class to use when finding a
|
236
|
+
# matching Part
|
235
237
|
|
236
238
|
# @overload expose(name, **options, &block)
|
237
239
|
# Define a value to be passed to the template. The return value of the
|
@@ -315,7 +317,8 @@ module Dry
|
|
315
317
|
#
|
316
318
|
# @param name [Symbol] name for the exposure
|
317
319
|
# @macro exposure_options
|
318
|
-
# @option options [Boolean] :default a default value to provide if there is no matching
|
320
|
+
# @option options [Boolean] :default a default value to provide if there is no matching
|
321
|
+
# input data
|
319
322
|
#
|
320
323
|
# @overload expose(*names, **options)
|
321
324
|
# Define multiple values to pass through from the input data (when there
|
@@ -326,17 +329,18 @@ module Dry
|
|
326
329
|
#
|
327
330
|
# @param names [Symbol] names for the exposures
|
328
331
|
# @macro exposure_options
|
329
|
-
# @option options [Boolean] :default a default value to provide if there is no matching
|
332
|
+
# @option options [Boolean] :default a default value to provide if there is no matching
|
333
|
+
# input data
|
330
334
|
#
|
331
335
|
# @see https://dry-rb.org/gems/dry-view/exposures/
|
332
336
|
#
|
333
337
|
# @api public
|
334
338
|
def self.expose(*names, **options, &block)
|
335
339
|
if names.length == 1
|
336
|
-
exposures.add(names.first, block, options)
|
340
|
+
exposures.add(names.first, block, **options)
|
337
341
|
else
|
338
342
|
names.each do |name|
|
339
|
-
exposures.add(name, options)
|
343
|
+
exposures.add(name, **options)
|
340
344
|
end
|
341
345
|
end
|
342
346
|
end
|
@@ -411,7 +415,7 @@ module Dry
|
|
411
415
|
config.paths,
|
412
416
|
format: format,
|
413
417
|
engine_mapping: config.renderer_engine_mapping,
|
414
|
-
**config.renderer_options
|
418
|
+
**config.renderer_options
|
415
419
|
)
|
416
420
|
}
|
417
421
|
end
|
@@ -467,7 +471,10 @@ module Dry
|
|
467
471
|
|
468
472
|
if layout?
|
469
473
|
layout_env = self.class.layout_env(format: format, context: context)
|
470
|
-
output = env.template(
|
474
|
+
output = env.template(
|
475
|
+
self.class.layout_path,
|
476
|
+
layout_env.scope(config.scope, layout_locals(locals))
|
477
|
+
) { output }
|
471
478
|
end
|
472
479
|
|
473
480
|
Rendered.new(output: output, locals: locals)
|
@@ -477,8 +484,8 @@ module Dry
|
|
477
484
|
|
478
485
|
# @api private
|
479
486
|
def ensure_config
|
480
|
-
raise UndefinedConfigError
|
481
|
-
raise UndefinedConfigError
|
487
|
+
raise UndefinedConfigError, :paths unless Array(config.paths).any?
|
488
|
+
raise UndefinedConfigError, :template unless config.template
|
482
489
|
end
|
483
490
|
|
484
491
|
# @api private
|
metadata
CHANGED
@@ -1,92 +1,98 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dry-view
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tim Riley
|
8
8
|
- Piotr Solnica
|
9
9
|
autorequire:
|
10
|
-
bindir:
|
10
|
+
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2024-11-20 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
|
-
name:
|
15
|
+
name: concurrent-ruby
|
16
16
|
requirement: !ruby/object:Gem::Requirement
|
17
17
|
requirements:
|
18
18
|
- - "~>"
|
19
19
|
- !ruby/object:Gem::Version
|
20
|
-
version: '
|
21
|
-
- - ">="
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version: 2.0.6
|
20
|
+
version: '1.0'
|
24
21
|
type: :runtime
|
25
22
|
prerelease: false
|
26
23
|
version_requirements: !ruby/object:Gem::Requirement
|
27
24
|
requirements:
|
28
25
|
- - "~>"
|
29
26
|
- !ruby/object:Gem::Version
|
30
|
-
version: '
|
31
|
-
- - ">="
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 2.0.6
|
27
|
+
version: '1.0'
|
34
28
|
- !ruby/object:Gem::Dependency
|
35
|
-
name: dry-
|
29
|
+
name: dry-configurable
|
36
30
|
requirement: !ruby/object:Gem::Requirement
|
37
31
|
requirements:
|
38
32
|
- - "~>"
|
39
33
|
- !ruby/object:Gem::Version
|
40
|
-
version: '0.
|
34
|
+
version: '0.1'
|
41
35
|
type: :runtime
|
42
36
|
prerelease: false
|
43
37
|
version_requirements: !ruby/object:Gem::Requirement
|
44
38
|
requirements:
|
45
39
|
- - "~>"
|
46
40
|
- !ruby/object:Gem::Version
|
47
|
-
version: '0.
|
41
|
+
version: '0.1'
|
48
42
|
- !ruby/object:Gem::Dependency
|
49
|
-
name: dry-
|
43
|
+
name: dry-core
|
50
44
|
requirement: !ruby/object:Gem::Requirement
|
51
45
|
requirements:
|
52
46
|
- - "~>"
|
53
47
|
- !ruby/object:Gem::Version
|
54
|
-
version: '0.
|
48
|
+
version: '0.9'
|
49
|
+
- - ">="
|
50
|
+
- !ruby/object:Gem::Version
|
51
|
+
version: '0.9'
|
55
52
|
type: :runtime
|
56
53
|
prerelease: false
|
57
54
|
version_requirements: !ruby/object:Gem::Requirement
|
58
55
|
requirements:
|
59
56
|
- - "~>"
|
60
57
|
- !ruby/object:Gem::Version
|
61
|
-
version: '0.
|
58
|
+
version: '0.9'
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0.9'
|
62
62
|
- !ruby/object:Gem::Dependency
|
63
|
-
name: dry-
|
63
|
+
name: dry-inflector
|
64
64
|
requirement: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '0.
|
68
|
+
version: '0.1'
|
69
69
|
type: :runtime
|
70
70
|
prerelease: false
|
71
71
|
version_requirements: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: '0.
|
75
|
+
version: '0.1'
|
76
76
|
- !ruby/object:Gem::Dependency
|
77
|
-
name:
|
77
|
+
name: tilt
|
78
78
|
requirement: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: '0
|
82
|
+
version: '2.0'
|
83
|
+
- - ">="
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: 2.0.6
|
83
86
|
type: :runtime
|
84
87
|
prerelease: false
|
85
88
|
version_requirements: !ruby/object:Gem::Requirement
|
86
89
|
requirements:
|
87
90
|
- - "~>"
|
88
91
|
- !ruby/object:Gem::Version
|
89
|
-
version: '0
|
92
|
+
version: '2.0'
|
93
|
+
- - ">="
|
94
|
+
- !ruby/object:Gem::Version
|
95
|
+
version: 2.0.6
|
90
96
|
- !ruby/object:Gem::Dependency
|
91
97
|
name: bundler
|
92
98
|
requirement: !ruby/object:Gem::Requirement
|
@@ -105,30 +111,30 @@ dependencies:
|
|
105
111
|
name: rake
|
106
112
|
requirement: !ruby/object:Gem::Requirement
|
107
113
|
requirements:
|
108
|
-
- - "
|
114
|
+
- - ">="
|
109
115
|
- !ruby/object:Gem::Version
|
110
|
-
version: '
|
116
|
+
version: '0'
|
111
117
|
type: :development
|
112
118
|
prerelease: false
|
113
119
|
version_requirements: !ruby/object:Gem::Requirement
|
114
120
|
requirements:
|
115
|
-
- - "
|
121
|
+
- - ">="
|
116
122
|
- !ruby/object:Gem::Version
|
117
|
-
version: '
|
123
|
+
version: '0'
|
118
124
|
- !ruby/object:Gem::Dependency
|
119
125
|
name: rspec
|
120
126
|
requirement: !ruby/object:Gem::Requirement
|
121
127
|
requirements:
|
122
|
-
- - "
|
128
|
+
- - ">="
|
123
129
|
- !ruby/object:Gem::Version
|
124
|
-
version: '
|
130
|
+
version: '0'
|
125
131
|
type: :development
|
126
132
|
prerelease: false
|
127
133
|
version_requirements: !ruby/object:Gem::Requirement
|
128
134
|
requirements:
|
129
|
-
- - "
|
135
|
+
- - ">="
|
130
136
|
- !ruby/object:Gem::Version
|
131
|
-
version: '
|
137
|
+
version: '0'
|
132
138
|
description: A complete, standalone view rendering system that gives you everything
|
133
139
|
you need to write well-factored view code
|
134
140
|
email:
|
@@ -138,20 +144,9 @@ executables: []
|
|
138
144
|
extensions: []
|
139
145
|
extra_rdoc_files: []
|
140
146
|
files:
|
141
|
-
- ".codeclimate.yml"
|
142
|
-
- ".gitignore"
|
143
|
-
- ".rspec"
|
144
|
-
- ".travis.yml"
|
145
|
-
- ".yardopts"
|
146
147
|
- CHANGELOG.md
|
147
|
-
-
|
148
|
-
- Gemfile
|
149
|
-
- LICENSE.md
|
148
|
+
- LICENSE
|
150
149
|
- README.md
|
151
|
-
- Rakefile
|
152
|
-
- bin/console
|
153
|
-
- bin/setup
|
154
|
-
- bin/setup_helpers.rb
|
155
150
|
- dry-view.gemspec
|
156
151
|
- lib/dry-view.rb
|
157
152
|
- lib/dry/view.rb
|
@@ -177,7 +172,11 @@ files:
|
|
177
172
|
homepage: https://dry-rb.org/gems/dry-view
|
178
173
|
licenses:
|
179
174
|
- MIT
|
180
|
-
metadata:
|
175
|
+
metadata:
|
176
|
+
allowed_push_host: https://rubygems.org
|
177
|
+
changelog_uri: https://github.com/dry-rb/dry-view/blob/main/CHANGELOG.md
|
178
|
+
source_code_uri: https://github.com/dry-rb/dry-view
|
179
|
+
bug_tracker_uri: https://github.com/dry-rb/dry-view/issues
|
181
180
|
post_install_message:
|
182
181
|
rdoc_options: []
|
183
182
|
require_paths:
|
@@ -186,14 +185,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
186
185
|
requirements:
|
187
186
|
- - ">="
|
188
187
|
- !ruby/object:Gem::Version
|
189
|
-
version:
|
188
|
+
version: 3.0.0
|
190
189
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
191
190
|
requirements:
|
192
191
|
- - ">="
|
193
192
|
- !ruby/object:Gem::Version
|
194
193
|
version: '0'
|
195
194
|
requirements: []
|
196
|
-
rubygems_version: 3.
|
195
|
+
rubygems_version: 3.3.27
|
197
196
|
signing_key:
|
198
197
|
specification_version: 4
|
199
198
|
summary: A complete, standalone view rendering system that gives you everything you
|
data/.codeclimate.yml
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
version: "2"
|
2
|
-
plugins:
|
3
|
-
rubocop:
|
4
|
-
enabled: true
|
5
|
-
checks:
|
6
|
-
Rubocop/AllCops:
|
7
|
-
TargetRubyVersion: 2.2
|
8
|
-
Rubocop/Metrics/ClassLength:
|
9
|
-
Max: 150
|
10
|
-
Rubocop/Metrics/LineLength:
|
11
|
-
Max: 100
|
12
|
-
Rubocop/Metrics/MethodLength:
|
13
|
-
Max: 20
|
14
|
-
exclude_patterns:
|
15
|
-
- "benchmarks/"
|
16
|
-
- "bin/"
|
17
|
-
- "examples/"
|
18
|
-
- "spec/"
|