Composables

The package provides a set of composables sufficient to start working with Laravel Sanctum authentication:

  • useSanctumAuth - provides access to the current user and authentication methods

  • useSanctumUser - provides access to the current user

  • useSanctumClient - provides access to the ofetch client with pre-configured CSRF token header and cookie management

  • useSanctumConfig - provides quick access to the module configuration