archtechx/airwire
Airwire bridges Laravel Livewire and Alpine.js, letting you call Livewire component methods directly from Alpine expressions through a small JavaScript API. It gives Alpine reactive access to server-side state without extra boilerplate, keeping interactive Laravel frontends simple.
This package is still early in its lifecycle (v0.1.x), so treat the README and the test suite as the source of truth. The v0.1.4 release specifically adds handling for the case where a model has no records, which is a common day-to-day concern in Laravel applications.
Minimal steps:
v0.1.4 changelog entry,First use case: a controller or API endpoint that lists records for a model and currently returns a blank response, an empty paginator with confusing metadata, or an error when no rows exist. Use the package’s empty-record handling to normalize that path and return a predictable empty collection, message, or response shape.
Use the package at the boundary where empty model results become user-visible or API-visible.
200 with data: [], or a domain-specific 404, depending on your API semantics. Keep the decision in one place rather than scattering isEmpty() checks across controllers.@forelse/@empty blocks across index pages.->get() and then manually checking count() in every caller.total() === 0 and items() === []. Empty paginators often still render pagination links unless explicitly suppressed.0.1.x package, pin to 0.1.4 or use a tight constraint until the API stabilizes. Review each patch release before upgrading.total(), count(), items(), and whether the package alters paginator metadata.with() calls from the non-empty path.toSql() and getBindings() when the package reports an empty result unexpectedly. Also check whether global scopes or soft deletes are filtering rows.php artisan config:clear after changes. Check for model-to-handler mappings that may need registration.How can I help you explore Laravel packages today?