Skip to content

Conversation

@andrefelipe18
Copy link
Contributor

This pull request introduces a new global helper function for creating Hunter instances and updates the documentation to reflect this addition. It also modifies the autoload configuration in composer.json to include the new helper file.

Core functionality updates:

  • Added a global helper function hunter in src/helpers.php to simplify the creation of Hunter instances for a given model class. This function includes type declarations and error handling for invalid class names.

Configuration changes:

  • Updated the composer.json autoload section to include the src/helpers.php file under the files key, ensuring the helper function is automatically loaded.

Documentation updates:

  • Updated docs/examples.md to demonstrate the usage of the new hunter helper function alongside the original Hunter::for method. This includes examples of activating inactive users using both approaches. [1] [2] [3]

@andrefelipe18 andrefelipe18 self-assigned this Jun 25, 2025
@andrefelipe18 andrefelipe18 merged commit 4abd80d into main Jun 25, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants