github ViewComponent/view_component v4.21.0
4.21.0

3 hours ago

4.21.0

  • Avoid NameError during eager loading when components include modules with temporary names.

    Joel Hawksley

  • Avoid repeated scanning of unterminated ERB tags during cache dependency discovery.

    Joel Hawksley

  • Skip dependency compilation for static ERB markup and literal templates while preserving helper-rendered component tracking.

    Joel Hawksley

  • Track helper-rendered component cache dependencies, enforce single-use instances on cache hits, and emit one render notification per self-cached render.

    Joel Hawksley

  • Resolve symbolic translation defaults in sidecars, restore request URL state in tests, and refresh inherited templates whenever template reloading is enabled.

    Joel Hawksley

  • Reuse existing GitHub releases when retrying a failed gem publish.

    Joel Hawksley

  • Prevent self-cache key collisions and track component references in views and format-specific partial dependencies.

    Joel Hawksley

  • Isolate preview and request parameters, honor preview locale callbacks, restore controller view contexts, and accept nil translation keys.

    Joel Hawksley

  • Honor negative generator flags and preserve pre-release versions throughout release automation. Report gem publishing failures.

    Joel Hawksley

  • Fix fragment cache collisions after render_parent, missing relative-partial and inherited-template dependencies, format fallback cache collisions, and stale cached output after development template edits.

    Joel Hawksley

  • Fix template method collisions between formats and variants, preserve default slot state, and copy collection spacer slots independently.

    Joel Hawksley

  • Apply --skip-suffix to all generated component files and restore full request URLs after with_request_url blocks.

    Joel Hawksley

  • Reset the assertion page when rendering a preview so assertions inspect the latest output.

    Joel Hawksley

  • Rediscover templates after development changes, including added or removed variants and parent templates.

    Joel Hawksley

  • Include all requested variants in output cache keys, preserving fallback order.

    Joel Hawksley

  • Resolve cache dependencies in their Ruby lexical namespaces and component template scopes.

    Joel Hawksley

  • Keep default slot configuration isolated between parent components and subclasses.

    Joel Hawksley

  • Preserve the calling view's translation scope when a component returns cached output or rejects content.

    Joel Hawksley

  • Reduce rendering and collection overhead, and speed up eager loading by sharing template-path parsing and avoiding redundant template and ancestor checks.

    Joel Hawksley

  • Speed up eager loading by sharing source-file reads between template compilation and cache digest precomputation, and reduce nested-render and default-slot lookup overhead.

    Joel Hawksley

  • Speed up eager loading by sharing sidecar directory listings during compilation, and reduce per-render state reset overhead.

    Joel Hawksley

  • Ignore unresolved partial dependencies inferred from dynamic renders, such as render UI.button, without requiring configuration for component facades. Real partials and explicit dependencies are preserved.

    Joel Hawksley

  • Raise ViewComponent::UnknownConfigOptionError when setting a config.view_component option that doesn't exist, rather than ignoring it. This includes options renamed or removed in 4.0, such as preview_controller (now previews.controller), and the error names the replacement. Replacing previews or generate with a hash preserves this validation, including through Hash mutation methods such as merge!, update, store, and replace.

    Fiona Burcombe

Don't miss a new view_component release

NewReleases is sending notifications on new releases.