liberusoftware/currency-context-livewire
A Livewire component for the liberusoftware/currency-context package that lets users view and switch the active display currency in your Laravel app. It keeps currency state reactive across Livewire components and offers a simple, framework-friendly API for building currency-aware interfaces.
Architecture fit. This package is a presentation adapter that binds Livewire components to a currency context module. As a TPM, I read that as a deliberate separation-of-concerns play: the underlying currency context domain (session/user/tenant-scoped currency selection, likely resolution and formatting rules) lives elsewhere, and this package supplies the Livewire-facing UI surface. That is architecturally sound if your application already uses a modular Laravel monolith with Livewire as the rendering layer. It is a poor fit for API-first, Inertia/Vue, or Blade-only applications, where it adds a dependency with no usable surface.
Integration feasibility. The mechanics are low-complexity — a Composer install, service provider auto-discovery, Livewire component registration, and view publishing. The real cost is not integration effort but pre-integration verification: the README-level contract (what components exist, what events they emit, how state is persisted) must be confirmed by reading source, because the signals available here are thin. Zero stars, zero dependents, and a NOASSERTION license mean there is no community validation and no confirmed legal posture.
Technical risk. Three risks dominate. First, license ambiguity — NOASSERTION is a blocker for most enterprise legal reviews until clarified in writing; treat this as a hard gate, not a formality. Second, bus-factor and provenance — 0 stars / 0 dependents on a package dated 2026-10-26 suggests an internal or pre-public module, not a maintained OSS dependency. Third, transitive coupling — the adapter is meaningless without its sibling currency-context domain package, so you are effectively adopting an ecosystem, not a package, and must evaluate that dependency's stability and versioning too.
Key questions. (1) What is the actual license, and can the maintainer state it explicitly? (2) Which currency-context domain package version does this require, and is that package's API stable? (3) How is currency selection persisted — session, user column, tenant config? That determines multi-tenant and multi-user correctness. (4) Does it handle locale/formatting, or only selection state? (5) Are there tests, and at what coverage? (6) Is the 2026-10-26 date a release or a republish? (7) What is the intended support model — is this effectively a vendored internal module?
Stack fit. Adopt only if the target stack is Laravel + Livewire with a modular package structure. The "module-*" naming convention implies a host application that already consumes a family of first-party modules; this package should slot into that same registry and service-provider pattern. If the host is not modularized, you will be introducing a packaging convention that nothing else in the codebase follows — a coherence cost with no offsetting benefit.
Migration path. Treat this as a greenfield-only dependency. Retrofitting currency context into an existing app means auditing every price display, cart total, invoice, and reporting surface for hardcoded currency assumptions. That audit is the real project, and it dwarfs the adapter install. Recommended path: prove the concept in a single bounded surface (e.g., a product listing or cart summary) before any broader commitment.
Compatibility. Verify PHP and Laravel version constraints against the host's current floor, and confirm the Livewire major version (v2 vs v3 have materially different component lifecycles and would force either an upgrade or a downgrade path). Because the domain dependency is separate, you must validate the pairing of adapter and domain versions, not each in isolation — pin both explicitly.
Sequencing. (1) License and provenance clearance. (2) Source read and test-coverage check. (3) Confirm domain-package pairing. (4) Spike in a non-critical surface behind a feature flag. (5) Internal README documenting the actual component contract. (6) Decide on vendoring — given the bus factor, forking into a controlled internal repository is the prudent default, which converts a dependency decision into a maintenance-ownership decision.
Maintenance. The honest framing for stakeholders: with 0 stars and 0 dependents, there is no realistic prospect of upstream fixes, security patches, or compatibility updates for new Laravel/Livewire releases. Adopting this is closer to vendoring than to consuming OSS. Budget for a named internal owner and a periodic review cadence — realistically a few hours per quarter plus reactive work on framework upgrades. That is acceptable for a small adapter; it is not acceptable if the team cannot name that owner.
Support. No community, no issue-tracker signal, no documented support channel. Escalation is entirely internal. This must be stated plainly in any adoption recommendation — the "support contract" is your own engineering team.
Scaling. The package itself is thin presentation glue; it will not be the scaling bottleneck. Currency resolution and formatting logic live in the domain package, and that is where caching, per-request resolution cost, and multi-tenant correctness need scrutiny. Assess scaling at the domain layer, and verify the adapter does not re-resolve context on every Livewire re-render — a plausible inefficiency in Livewire adapters, since components re-render frequently.
Failure modes. (1) Silent currency drift — the adapter renders but the domain context is unset, so a default currency is shown without warning; this is the highest-severity failure because it is a correctness/money bug, not a crash. (2) Version skew — Livewire upgrade breaks component lifecycle with no upstream fix. (3) License challenge — legal blocks use post-integration, forcing rework. (4) Domain coupling break — a bump in the domain package silently changes adapter behavior. Mitigation for (1) and (4): pin exact versions, add an integration test asserting resolved currency per context, and fail loudly on unset context rather than defaulting.
Ramp-up. Low technical ramp-up (small, conventional Laravel package), but non-trivial contextual ramp-up: engineers must learn the domain package, the modular registry conventions, and the persistence model. Expect roughly a day to first working component for a Laravel-fluent engineer, and a week to genuine confidence across the domain/adapter boundary. Factor that into the estimate — the install is not the cost.
TPM recommendation. Conditional proceed, gated on license clarification and a named internal owner, scoped to a single pilot surface, with vendoring as the default posture. Do not adopt as a general-purpose dependency until the license and domain-package stability questions are closed.
How can I help you explore Laravel packages today?