rubocop-view_component 0.6.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/.rubocop.yml +4 -0
- data/{CLAUDE.md → AGENTS.md} +6 -14
- data/Appraisals +5 -0
- data/README.md +50 -27
- data/config/default.yml +6 -5
- data/docs/rubydex.md +136 -0
- data/gemfiles/rubocop_minimum.gemfile +13 -0
- data/gemfiles/rubocop_minimum.gemfile.lock +162 -0
- data/lib/rubocop/cop/view_component/base.rb +56 -7
- data/lib/rubocop/cop/view_component/prefer_composition.rb +42 -9
- data/lib/rubocop/cop/view_component/prefer_private_methods.rb +46 -13
- data/lib/rubocop/cop/view_component/rspec_scope.rb +98 -0
- data/lib/rubocop/cop/view_component/supplementary_index.rb +142 -0
- data/lib/rubocop/cop/view_component/test_rendered_output.rb +107 -11
- data/lib/rubocop/view_component/version.rb +1 -1
- data/script/verify +29 -16
- data/spec/expected_flowbite_failures.yml +64 -0
- data/spec/expected_govuk_failures.yml +10 -12
- data/spec/expected_polaris_failures.yml +2 -0
- data/spec/expected_primer_failures.yml +60 -2
- data/spec/rubocop/cop/view_component/base_spec.rb +108 -0
- data/spec/rubocop/cop/view_component/component_suffix_spec.rb +0 -58
- data/spec/rubocop/cop/view_component/missing_preview_spec.rb +1 -42
- data/spec/rubocop/cop/view_component/prefer_composition_spec.rb +91 -4
- data/spec/rubocop/cop/view_component/prefer_private_methods_spec.rb +126 -4
- data/spec/rubocop/cop/view_component/test_rendered_output_spec.rb +287 -4
- data/spec/spec_helper.rb +10 -0
- data/spec/support/project_index_helpers.rb +71 -0
- data/verification/flowbite_rubocop_config.yml +12 -0
- data/verification/govuk_rubocop_config.yml +3 -6
- data/verification/libraries.yml +4 -0
- data/verification/polaris_rubocop_config.yml +3 -7
- data/verification/primer_rubocop_config.yml +5 -7
- metadata +29 -5
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rubocop-view_component
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.8.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Andy Waite
|
|
@@ -65,20 +65,34 @@ dependencies:
|
|
|
65
65
|
- - ">="
|
|
66
66
|
- !ruby/object:Gem::Version
|
|
67
67
|
version: '0'
|
|
68
|
+
- !ruby/object:Gem::Dependency
|
|
69
|
+
name: rubydex
|
|
70
|
+
requirement: !ruby/object:Gem::Requirement
|
|
71
|
+
requirements:
|
|
72
|
+
- - ">="
|
|
73
|
+
- !ruby/object:Gem::Version
|
|
74
|
+
version: '0'
|
|
75
|
+
type: :runtime
|
|
76
|
+
prerelease: false
|
|
77
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
78
|
+
requirements:
|
|
79
|
+
- - ">="
|
|
80
|
+
- !ruby/object:Gem::Version
|
|
81
|
+
version: '0'
|
|
68
82
|
- !ruby/object:Gem::Dependency
|
|
69
83
|
name: rubocop
|
|
70
84
|
requirement: !ruby/object:Gem::Requirement
|
|
71
85
|
requirements:
|
|
72
86
|
- - ">="
|
|
73
87
|
- !ruby/object:Gem::Version
|
|
74
|
-
version: 1.
|
|
88
|
+
version: 1.89.0
|
|
75
89
|
type: :runtime
|
|
76
90
|
prerelease: false
|
|
77
91
|
version_requirements: !ruby/object:Gem::Requirement
|
|
78
92
|
requirements:
|
|
79
93
|
- - ">="
|
|
80
94
|
- !ruby/object:Gem::Version
|
|
81
|
-
version: 1.
|
|
95
|
+
version: 1.89.0
|
|
82
96
|
description: A RuboCop extension that enforces ViewComponent best practices and conventions
|
|
83
97
|
email:
|
|
84
98
|
- andyw8@users.noreply.github.com
|
|
@@ -88,11 +102,15 @@ extra_rdoc_files: []
|
|
|
88
102
|
files:
|
|
89
103
|
- ".rspec"
|
|
90
104
|
- ".rubocop.yml"
|
|
91
|
-
-
|
|
105
|
+
- AGENTS.md
|
|
106
|
+
- Appraisals
|
|
92
107
|
- LICENSE.txt
|
|
93
108
|
- README.md
|
|
94
109
|
- Rakefile
|
|
95
110
|
- config/default.yml
|
|
111
|
+
- docs/rubydex.md
|
|
112
|
+
- gemfiles/rubocop_minimum.gemfile
|
|
113
|
+
- gemfiles/rubocop_minimum.gemfile.lock
|
|
96
114
|
- lib/rubocop-view_component.rb
|
|
97
115
|
- lib/rubocop/cop/view_component/base.rb
|
|
98
116
|
- lib/rubocop/cop/view_component/component_suffix.rb
|
|
@@ -101,6 +119,8 @@ files:
|
|
|
101
119
|
- lib/rubocop/cop/view_component/prefer_composition.rb
|
|
102
120
|
- lib/rubocop/cop/view_component/prefer_private_methods.rb
|
|
103
121
|
- lib/rubocop/cop/view_component/prefer_slots.rb
|
|
122
|
+
- lib/rubocop/cop/view_component/rspec_scope.rb
|
|
123
|
+
- lib/rubocop/cop/view_component/supplementary_index.rb
|
|
104
124
|
- lib/rubocop/cop/view_component/template_analyzer.rb
|
|
105
125
|
- lib/rubocop/cop/view_component/test_rendered_output.rb
|
|
106
126
|
- lib/rubocop/cop/view_component_cops.rb
|
|
@@ -108,11 +128,13 @@ files:
|
|
|
108
128
|
- lib/rubocop/view_component/plugin.rb
|
|
109
129
|
- lib/rubocop/view_component/version.rb
|
|
110
130
|
- script/verify
|
|
131
|
+
- spec/expected_flowbite_failures.yml
|
|
111
132
|
- spec/expected_govuk_failures.yml
|
|
112
133
|
- spec/expected_polaris_failures.yml
|
|
113
134
|
- spec/expected_primer_failures.yml
|
|
114
135
|
- spec/fixtures/components/template_method_component.html.erb
|
|
115
136
|
- spec/fixtures/components/template_method_component.rb
|
|
137
|
+
- spec/rubocop/cop/view_component/base_spec.rb
|
|
116
138
|
- spec/rubocop/cop/view_component/component_suffix_spec.rb
|
|
117
139
|
- spec/rubocop/cop/view_component/missing_preview_spec.rb
|
|
118
140
|
- spec/rubocop/cop/view_component/no_global_state_spec.rb
|
|
@@ -121,6 +143,8 @@ files:
|
|
|
121
143
|
- spec/rubocop/cop/view_component/prefer_slots_spec.rb
|
|
122
144
|
- spec/rubocop/cop/view_component/test_rendered_output_spec.rb
|
|
123
145
|
- spec/spec_helper.rb
|
|
146
|
+
- spec/support/project_index_helpers.rb
|
|
147
|
+
- verification/flowbite_rubocop_config.yml
|
|
124
148
|
- verification/govuk_rubocop_config.yml
|
|
125
149
|
- verification/libraries.yml
|
|
126
150
|
- verification/polaris_rubocop_config.yml
|
|
@@ -147,7 +171,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
147
171
|
- !ruby/object:Gem::Version
|
|
148
172
|
version: '0'
|
|
149
173
|
requirements: []
|
|
150
|
-
rubygems_version:
|
|
174
|
+
rubygems_version: 4.0.20
|
|
151
175
|
specification_version: 4
|
|
152
176
|
summary: RuboCop extension for ViewComponent best practices
|
|
153
177
|
test_files: []
|