magewire-hyva-checkout-backwards-compatibility

Migrate Hyvä Checkout v1 components to Magewire v3 with runtime shims.

262|47|Updated Oct 8, 2021
One-click install
npx skills add https://github.com/magewirephp/magewire --skill magewire-hyva-checkout-backwards-compatibility
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: magewire-hyva-checkout-backwards-compatibility
Source: https://github.com/magewirephp/magewire/tree/main/themes/Hyva/.claude/skills/magewire-hyva-checkout-backwards-compatibility
Command: npx skills add https://github.com/magewirephp/magewire --skill magewire-hyva-checkout-backwards-compatibility

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Hyvä Checkout v1 components migrated to Magewire v3 require a compatibility layer to preserve behavior and avoid rewriting components. This skill provides a Hyvä-themed backwards-compatibility layer with runtime JS shims and PHP features to bridge v2 and v3 behavior.

Core Features & Use Cases

  • Theme-scoped backwards compatibility that auto-enables for components inside the hyva-checkout-main container.
  • Four JS templates and PHP features that rewrite wire directives and proxy component state to align v2/v3 behavior.
  • Opt-out mechanism via the #[HandleBackwardsCompatibility] attribute and DI-based configuration for advanced usage.

Quick Start

Install and activate this skill within themes/Hyva, then follow the documented migration steps to enable Hyvä Checkout backwards compatibility for Magewire v3 components.

Frequently Asked Questions about magewire-hyva-checkout-backwards-compatibility

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate Hyvä Checkout v1 components to Magewire v3 without rewriting them?

Migrate Hyvä Checkout v1 components to Magewire v3 by installing a backwards-compatibility layer that provides runtime JS shims and PHP features. This layer rewrites wire directives and proxies component state to preserve v2 behavior inside v3.

When do I need a backwards-compatibility layer for Magewire in Hyvä Checkout?

You need a backwards-compatibility layer when upgrading to Magewire v3 while maintaining Hyvä Checkout v1 components. It bridges v2 and v3 behavior automatically for any component rendered inside the hyva-checkout-main container.

Does Magewire v3 backwards compatibility require specific Hyvä theme modules?

Yes, Magewire v3 backwards compatibility requires the magewire-backwards-compatibility and magewire-theming modules to be installed and active within your Hyvä theme environment to function correctly.

Can I opt out of the Magewire backwards compatibility layer for specific components?

Yes, you can opt out of the Magewire backwards compatibility layer for specific components by applying the #[HandleBackwardsCompatibility] attribute or using DI-based configuration for advanced custom usage.

What is the best way to preserve Magewire $wire behavior during a Hyvä Checkout upgrade?

The best way to preserve Magewire $wire behavior is using a theme-scoped compatibility layer with JS templates that proxy component state. This aligns v2 and v3 behavior without requiring manual component rewrites.

Why are my Magewire directives breaking after upgrading to v3 in Hyvä Checkout?

Magewire directives break after upgrading to v3 because v2 behavior is not natively supported. A compatibility layer applies JS templates and PHP features to rewrite directives and proxy $wire, restoring expected functionality.