Browse / Mobile Development / NativePHP Events

NativePHP Events

Handles asynchronous events from native device features like the camera, scanner, and biometrics within Laravel and Livewire applications.

The source repository doesn't declare a license. Check its terms before reusing the code.

Key features

  • Documentation of asynchronous native events for camera, scanner, biometrics, and geolocation
  • Guidance for creating and using custom event classes via the fluent API
  • Implementation guidance for the #[OnNative] attribute in Livewire components
  • Best practices for registering standard Laravel backend event listeners
  • Patterns for correlating requests and responses using unique tracking IDs

Use cases

  • Responding to photo capture or video recording completion in a mobile UI
  • Handling biometric authentication results for secure user actions
  • Processing location data or scanned QR codes within a Laravel backend

FAQ

When should I use this skill?

Use this skill when you are developing mobile features that require feedback from native device APIs. It is essential for handling responses like 'PhotoTaken', 'CodeScanned', or 'LocationReceived' within your Livewire components or Laravel backend.

What does the NativePHP Events skill do?

This skill equips Claude Code with the specialized knowledge to implement and manage asynchronous events from mobile device hardware—such as cameras, scanners, and biometrics—within NativePHP-powered Laravel applications.

How does this skill improve my mobile development workflow?

It provides instant access to event documentation, fluent API patterns for tracking request IDs, and best practices for both frontend Livewire listeners and backend Laravel EventServiceProvider registrations, significantly reducing debugging time.

Why is the #[OnNative] attribute significant in this skill?

The #[OnNative] attribute is a required pattern for NativePHP. This skill ensures Claude uses it correctly to handle event class resolution and the mandatory 'native:' prefix, preventing common integration errors in Livewire components.

Does this skill support custom event handling?

Yes, it provides guidance on extending built-in event classes to create custom event logic, allowing you to trigger specific behaviors using the fluent API and correlate requests using unique tracking IDs.