Skip to content

chore(deps): update dependency view_component to v3

DLD Bot requested to merge renovate/view_component-3.x into trunk

This MR contains the following updates:

Package Update Change
view_component (source, changelog) major "< 2.83.1" -> "< 3.12.2"

Release Notes

viewcomponent/view_component (view_component)

v3.12.1

Compare Source

  • Ensure content is rendered correctly for forwarded slots.

    Cameron Dutro

v3.12.0

Compare Source

  • 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 the view_component_path option has been changed to app/views/components, the generator will put the spec file in spec/views/components. If the view_component_path doesn't start with app/, then the generator will fall back to spec/components/.

    This feature is enabled via the config.view_component.generate.use_component_path_for_rspec_tests option, defaulting to false. The default will change to true in ViewComponent v4.

    William Mathewson

v3.11.0

Compare Source

  • 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

Compare Source

  • Fix html escaping in #call for non-strings.

    Reegan Viljoen, Cameron Dutro

  • Add output_preamble to match output_postamble, using the same safety checks.

    Kali Donovan, Michael Daross

  • Exclude html escaping of I18n reserved keys with I18n::RESERVED_KEYS rather than I18n.reserved_keys_pattern.

    Nick Coyne

  • Update CI configuration to use Appraisal.

    Hans Lemuet, Simon Fish

v3.9.0

Compare Source

  • Don’t break rails stats if ViewComponent path is missing.

    Claudio Baccigalupo

  • Add deprecation warnings for EOL ruby and Rails versions and patches associated with them.

    Reegan Viljoen

  • Add support for Ruby 3.3.

    *Reegan Viljoen*
  • Allow translations to be inherited and overridden in subclasses.

    Elia Schito

  • Resolve console warnings when running test suite.

    Joel Hawksley

  • Fix spelling in a local variable.

    Olle Jonsson

  • Avoid duplicating rendered string when output_postamble is blank.

    Mitchell Henke

  • Ensure HTML output safety.

    Cameron Dutro

v3.8.0

Compare Source

  • Use correct value for the config.action_dispatch.show_exceptions config option for edge Rails.

    Cameron Dutro

  • Remove unsupported versions of Rails & Ruby from CI matrix.

    Reegan Viljoen

  • Raise error when uncountable slot names are used in renders_many

    Hugo Chantelauze Reegan Viljoen

  • Replace usage of String#ends_with? with String#end_with? to reduce the dependency on ActiveSupport core extensions.

    halo

  • Don't add ActionDispatch::Static middleware unless public_file_server.enabled.

    Daniel Gonzalez Reegan Viljoen

  • Resolve an issue where slots starting with call would cause a NameError

    Blake Williams

  • Add use_helper API.

    Reegan Viljoen

  • Fix bug where the Rails module wasn't being searched from the root namespace.

    Zenéixe

  • Fix bug where #with_request_url, set the incorrect request.fullpath.

    Nachiket Pusalkar

  • Allow setting method when using the with_request_url test helper.

    Andrew Duthie

v3.7.0

Compare Source

  • Support Rails 7.1 in CI.

    Reegan Viljoen Cameron Dutro

  • Document the capture compatibility patch on the Known issues page.

    Simon Fish

  • Add Simundia to list of companies using ViewComponent.

    Alexandre Ignjatovic

  • Reduce UnboundMethod objects by memoizing initialize_parameters.

    Rainer Borene

  • Improve docs about inline templates interpolation.

    Hans Lemuet

  • Update generators.md to clarify the way of changing config.view_component.view_component_path.

    Shozo Hatta

  • Attempt to fix Ferrum timeout errors by creating driver with unique name.

    Cameron Dutro

v3.6.0

Compare Source

  • Refer to helpers in NameError message in development and test environments.

    Simon Fish

  • Fix API documentation and revert unnecessary change in preview.rb.

    Richard Macklin

  • Initialize ViewComponent::Config with defaults before framework load.

    Simon Fish

  • Add 3.2 to the list of Ruby CI versions

    Igor Drozdov

  • Stop running PVC's docs:preview rake task in CI, as the old docsite has been removed.

    Cameron Dutro

  • Minor testing documentation improvement.

    Travis Gaff

  • Add SearchApi to users list.

    Sebastjan Prachovskij

  • Fix #with_request_url to ensure request.query_parameters is an instance of ActiveSupport::HashWithIndifferentAccess.

    milk1000cc

  • Add PeopleForce to list of companies using ViewComponent.

    Volodymyr Khandiuk

v3.5.0

Compare Source

v3.4.0

Compare Source

  • Avoid including Rails url_helpers into Preview class when they're not defined.

    Richard Macklin

  • Allow instrumentation to be automatically included in Server-Timing headers generated by Rails. To enable this set the config config.use_deprecated_instrumentation_name = false. The old key !render.view_component is deprecated: update ActiveSupport::Notification subscriptions to render.view_component.

    Travis Gaff

v3.3.0

Compare Source

  • Include InlineTemplate by default in Base. Note: It's no longer necessary to include ViewComponent::InlineTemplate to use inline templates.

    Joel Hawksley

  • Allow Setting host when using the with_request_url test helper.

    Daniel Alfaro

  • Resolve ambiguous preview paths when using components without the Component suffix.

    Reed Law

v3.2.0

Compare Source

  • Fix viewcomponent.org Axe violations.

    Joel Hawksley

  • Fix example of RSpec configuration in docs

    Pasha Kalashnikov

  • Add URL helpers to previews

    Reegan Viljoen

v3.1.0

Compare Source

  • Check defined?(Rails) && Rails.application before using ViewComponent::Base.config.view_component_path.

    Donapieppo

  • Allow customization of polymorphic slot setters.

    Cameron Dutro

  • Fix duplication in configuration docs.

    Tom Chen

  • Fix helpers not reloading in development.

    Jonathan del Strother

  • Add SECURITY.md.

    Joel Hawksley

  • Add Ophelos to list of companies using ViewComponent.

    Graham Rogers

  • Add FlightLogger to list of companies using ViewComponent.

    Joseph Carpenter

  • Fix coverage reports overwriting each other when running locally.

    Jonathan del Strother

  • Add @​reeganviljoen to triage team.

    Reegan Viljoen

v3.0.0

Compare Source

1,000+ days and 100+ releases later, the 200+ contributors to ViewComponent are proud to ship v3.0.0!

We're so grateful for all the work of community members to get us to this release. Whether it’s filing bug reports, designing APIs in long-winded discussion threads, or writing code itself, ViewComponent is built by the community, for the community. We couldn’t be more proud of what we’re building together

This release makes the following breaking changes, many of which have long been deprecated:

  • BREAKING: Remove deprecated slots setter methods. Use with_SLOT_NAME instead.

    Joel Hawksley

  • BREAKING: Remove deprecated SlotsV1 in favor of current SlotsV2.

    Joel Hawksley

  • BREAKING: Remove deprecated content_areas feature. Use Slots instead.

    Joel Hawksley

  • BREAKING: Remove deprecated support for loading ViewComponent engine manually. Make sure require "view_component/engine" is removed from Gemfile.

    Joel Hawksley

  • BREAKING: Remove deprecated generate_* methods. Use generate.* instead.

    Joel Hawksley

  • BREAKING: Remove deprecated with_variant method.

    Joel Hawksley

  • BREAKING: Remove deprecated rendered_component in favor of rendered_content.

    Joel Hawksley

  • BREAKING: Remove deprecated config.preview_path in favor of config.preview_paths.

    Joel Hawksley

  • BREAKING: Support Ruby 2.7+ instead of 2.4+

    Joel Hawksley

  • BREAKING: Remove deprecated before_render_check.

    Joel Hawksley

  • BREAKING: Change counter variable to start iterating from 0 instead of 1.

    Frank S

  • BREAKING: #SLOT_NAME getter no longer accepts arguments. This change was missed as part of the earlier deprecation in 3.0.0.rc1.

    Joel Hawksley

  • BREAKING: Raise TranslateCalledBeforeRenderError, ControllerCalledBeforeRenderError, or HelpersCalledBeforeRenderError instead of ViewContextCalledBeforeRenderError.

    Joel Hawksley

  • BREAKING: Raise SlotPredicateNameError, RedefinedSlotError, ReservedSingularSlotNameError, ContentSlotNameError, InvalidSlotDefinitionError, ReservedPluralSlotNameError, ContentAlreadySetForPolymorphicSlotErrror, SystemTestControllerOnlyAllowedInTestError, SystemTestControllerNefariousPathError, NoMatchingTemplatesForPreviewError, MultipleMatchingTemplatesForPreviewError, DuplicateContentError, EmptyOrInvalidInitializerError, MissingCollectionArgumentError, ReservedParameterError, InvalidCollectionArgumentError, MultipleInlineTemplatesError, MissingPreviewTemplateError, DuplicateSlotContentError or NilWithContentError instead of generic error classes.

    Joel Hawksley

  • BREAKING: Rename SlotV2 to Slot and SlotableV2 to Slotable.

    Joel Hawksley

  • BREAKING: Incorporate PolymorphicSlots into Slotable. To migrate, remove any references to PolymorphicSlots as they are no longer necessary.

    Joel Hawksley

  • BREAKING: Rename private TestHelpers#controller, #build_controller, #request, and #preview_class to avoid conflicts. Note: While these methods were undocumented and marked as private, they were accessible in tests. As such, we're considering this to be a breaking change.

    Joel Hawksley

v2.83.0

Compare Source

  • Ensure HTML output safety.

    Cameron Dutro

v2.82.0

Compare Source

  • Revert "Avoid loading ActionView::Base during initialization (#​1528)"

    Jon Rohan

  • Fix tests using with_rendered_component_path with custom layouts.

    Ian Hollander

v2.81.0

Compare Source

  • Adjust the way response objects are set on the preview controller to work around a recent change in Rails main.

    Cameron Dutro

  • Fix typo in "Generate a Stimulus controller" documentation.

    Ben Trewern

  • Modify the render_in_view_context test helper to forward its args to the block.

    Cameron Dutro

v2.80.0

Compare Source

  • Move system test endpoint out of the unrelated previews controller.

    Edwin Mak

  • Display Ruby 2.7 deprecation notice only once, when starting the application.

    Henrik Hauge Bjørnskov

  • Require Rails 5.2+ in gemspec and update documentation.

    Drew Bragg

  • Add documentation for using with_rendered_component_path with RSpec.

    Edwin Mak

v2.79.0

Compare Source

  • Add ability to pass explicit preview_path to preview generator.

    Erinna Chen

  • Add with_rendered_component_path helper for writing component system tests.

    Edwin Mak

  • Include gem name and deprecation horizon in every deprecation message.

    Jan Klimo

v2.78.0

Compare Source

  • Support variants with dots in their names.

    Javi Martín

v2.77.0

Compare Source

  • Support variants with dashes in their names.

    Javi Martín

v2.76.0

Compare Source

  • Component.with_collection supports components that accept splatted keyword arguments.

    Zee Spencer

  • Remove config.view_component.use_consistent_rendering_lifecycle since it is no longer planned for 3.0.

    Blake Williams

  • Prevent polymorphic slots from calculating content when setting a slot.

    Blake Williams

  • Add ability to pass in the preview class to render_preview.

    Jon Rohan

  • Fix issue causing PVC tests to fail in CI.

    Cameron Dutro

  • Fix YARD docs build task.

    Hans Lemuet

  • Add Startup Jobs to list of companies using ViewComponent.

    Marc Köhlbrugge

  • Run PVC's accessibility tests in a single process to avoid resource contention in CI.

    Cameron Dutro

v2.75.0

Compare Source

  • Avoid loading ActionView::Base during Rails initialization.

    Jonathan del Strother

  • Mention lambda slots rendering returned values lazily in the guide.

    Graham Rogers

  • Add "ViewComponent In The Wild" articles to resources.

    Alexander Baygeldin

v2.74.1

Compare Source

  • Add more users of ViewComponent to docs.

    Joel Hawksley

  • Add a known issue for usage with turbo_frame_tag to the documentation.

    Vlad Radulescu

  • Add note about system testing components with previews.

    Joel Hawksley

  • Remove locking mechanisms from the compiler.

    Cameron Dutro

v2.74.0

Compare Source

  • Add Avo to list of companies using ViewComponent.

    Adrian Marin

  • Promote experimental _output_postamble method to public API as output_postamble.

    Joel Hawksley

  • Promote experimental _sidecar_files method to public API as sidecar_files.

    Joel Hawksley

  • Fix show_previews regression introduced in 2.73.0.

    Andy Baranov

  • with_request_url test helper supports router constraints (such as Devise).

    Aotokitsuruya


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Never, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this MR and you won't be reminded about these updates again.


  • If you want to rebase/retry this MR, check this box

This MR has been generated by Renovate Bot.

Merge request reports