Releases: ViewComponent/view_component
v3.16.0
v3.15.1
-
Re-add
@private
, undocumented.identifier
method that was only meant for internal framework use but was used by some downstream consumers. This method will be removed in a coming minor release.Joel Hawksley
v3.15.0
-
Add basic internal testing for memory allocations.
Joel Hawksley
-
Add support for request formats.
Joel Hawksley
-
Add
rendered_json
test helper.Joel Hawksley
-
Add
with_format
test helper.Joel Hawksley
-
Warn if using Ruby < 3.2 or Rails < 7.1, which won't be supported by ViewComponent v4, to be released no earlier than April 1, 2025.
Joel Hawksley
-
Add Kicksite to list of companies using ViewComponent.
Adil Lari
-
Allow overridden slot methods to use
super
.Andrew Schwartz
-
Add Rails engine support to generators.
Tomasz Kowalewski
-
Register stats directories with
Rails::CodeStatistics.register_directory
to supportrails stats
in Rails 8.Petrik de Heus
-
Fixed type declaration for
ViewComponent::TestHelpers.with_controller_class
parameter.Graham Rogers
v3.14.0
-
Defer to built-in caching for language environment setup, rather than manually using
actions/cache
in CI.Simon Fish
-
Add test coverage for use of
turbo_stream
helpers in components whencapture_compatibility_patch_enabled
istrue
.Simon Fish
-
Add experimental
SlotableDefault
module, allowing components to define adefault_SLOTNAME
method to provide a default value for slots.Joel Hawksley
-
Add documentation on rendering ViewComponents outside of the view context.
Joel Hawksley
-
Look for preview files that end in
preview.rb
rather than_preview.rb
to allow previews to exist in sidecar directory with test files.Seth Herr
-
Add
assert_component_rendered
test helper.Reegan Viljoen
-
Add
prefix:
option touse_helpers
.Reegan Viljoen
-
Add support for Rails 7.2.
Reegan Viljoen
v3.13.0
-
Add ruby head and YJIT to CI.
Reegan Viljoen
-
Fixed a bug where inline templates where unable to remove trailing whitespace without throwing an error.
Reegan Viljoen
-
Fixed CI for Rails main.
Reegan Viljoen
-
Add
from:
option touse_helpers
to allow for more flexible helper inclusion from modules.Reegan Viljoen
-
Fixed ruby head matcher issue.
Reegan Viljoen
v3.12.1
v3.12.0
-
Remove offline links from resources.
Paulo Henrique Meneses
-
Fix templates not being correctly populated when caller location label has a prefix.
On the upstream version of Ruby, method owners are now included in backtraces as prefixes. This caused the call stack filtering to not work as intended and thus
source_location
to be incorrect for child ViewComponents, consequently not populating templates correctly.Allan Pires, Jason Kim
-
Use component path for generating RSpec files.
When generating new RSpec files for components, the generator will use the
view_component_path
value in the config to decide where to put the new spec file. For instance, if theview_component_path
option has been changed toapp/views/components
, the generator will put the spec file inspec/views/components
. If theview_component_path
doesn't start withapp/
, then the generator will fall back tospec/components/
.This feature is enabled via the
config.view_component.generate.use_component_path_for_rspec_tests
option, defaulting tofalse
. The default will change totrue
in ViewComponent v4.William Mathewson
v3.11.0
-
Fix running non-integration tests under Rails main.
Cameron Dutro
-
Better name and link for Avo.
Adrian Marin
-
Document using rack-mini-profiler with ViewComponent.
Thomas Carr
-
Move dependencies to gemspec.
Joel Hawksley
-
Include ViewComponent::UseHelpers by default.
Reegan Viljoen
-
Bump
puma
in Gemfile.lock.Cameron Dutro
-
Add Keenly to users list.
Vinoth
v3.10.0
-
Fix html escaping in
#call
for non-strings.Reegan Viljoen, Cameron Dutro
-
Add
output_preamble
to matchoutput_postamble
, using the same safety checks.Kali Donovan, Michael Daross
-
Exclude html escaping of I18n reserved keys with
I18n::RESERVED_KEYS
rather thanI18n.reserved_keys_pattern
.Nick Coyne
-
Update CI configuration to use
Appraisal
.Hans Lemuet, Simon Fish