Download the PHP package kylearch/ephemeral-users without Composer
On this page you can find all versions of the php package kylearch/ephemeral-users. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download kylearch/ephemeral-users
More information about kylearch/ephemeral-users
Files in kylearch/ephemeral-users
Download kylearch/ephemeral-users
More information about kylearch/ephemeral-users
Files in kylearch/ephemeral-users
Vendor kylearch
Package ephemeral-users
Short Description Laravel package for ephemeral (non-persistent) user instances
License MIT
Package ephemeral-users
Short Description Laravel package for ephemeral (non-persistent) user instances
License MIT
Please rate this library. Is it a good library?
Informations about the package ephemeral-users
Ephemeral Users for Laravel
A Laravel package for creating ephemeral (non-persistent) user instances. Perfect for handling anonymous users, session-based users, or any scenario where you need a User object without database persistence.
Features
- 🚫 Prevent Accidental Persistence - Ephemeral users throw exceptions when save attempts are made
- 📝 Automatic Logging - Track code paths that attempt to persist ephemeral users
- 🔧 Configurable Behavior - Choose between throwing exceptions or silently preventing saves
- 🎯 Type Safe - Full type hinting and interface support
- 📦 Easy Integration - Simple trait-based implementation
Installation
Add the package to your Laravel application:
Publish the configuration file (optional):
Usage
Basic Setup
Implement the interface and use the trait in your User model:
Creating Ephemeral Users
Persistence Protection
Attempting to save an ephemeral user will:
- Log the attempt (if logging is enabled)
- Throw an
EphemeralPersistenceException(if configured) - Prevent the save operation
Configuration
The package supports the following configuration options:
Use Cases
- Anonymous Users: Handle session-based users without database records
- Testing: Create test users without database persistence
- API Integration: Represent external users without local persistence
- Guest Checkout: Allow guest users with full User object interface
- Sample/Demo Flows: Enable trial experiences without account creation
License
MIT
All versions of ephemeral-users with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.2
illuminate/support Version ^11.0|^12.0
illuminate/database Version ^11.0|^12.0
illuminate/support Version ^11.0|^12.0
illuminate/database Version ^11.0|^12.0
The package kylearch/ephemeral-users contains the following files
Loading the files please wait ...