Download the PHP package satheez/laravel-settings without Composer
On this page you can find all versions of the php package satheez/laravel-settings. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download satheez/laravel-settings
More information about satheez/laravel-settings
Files in satheez/laravel-settings
Package laravel-settings
Short Description A database-backed key-value settings store for Laravel.
License MIT
Homepage https://github.com/Satheez/laravel-settings
Informations about the package laravel-settings
Laravel Settings
A focused, database-backed key-value settings store for Laravel.
Requirements
- PHP 8.3 or newer
- Laravel 12.60 or newer, or Laravel 13.10 or newer
Installation
Install the package:
Publish and run the migration:
Publish the configuration when the defaults need to be changed:
Usage
Inject the settings contract into application services:
The contract provides:
all() returns an associative array sorted by key. forget() returns whether a
row was deleted.
The facade is available when dependency injection is not practical:
Supported Values
Settings may contain JSON-safe values:
null- booleans
- integers and finite floats
- valid UTF-8 strings
- nested arrays containing supported values
Objects, resources, non-finite floats, and invalid UTF-8 strings are rejected
with an UnsupportedSettingValue exception.
Stored null, false, 0, 0.0, empty strings, and empty arrays are real
values. The default passed to get() is returned only when the key is absent.
Encryption
New values are encrypted by default with Laravel's application encrypter. Each stored payload records whether it is encrypted, so changing the global setting does not make existing version 2 rows unreadable.
Keep APP_KEY stable. Data encrypted with a previous key cannot be recovered
unless that key remains configured through Laravel's key rotation support.
Cache
Database payloads and missing-key lookups are cached by default:
Writes refresh affected cache entries. Deletes and legacy migrations invalidate them. Cache backend failures are not swallowed.
Database Configuration
The default table is settings on the application's default connection:
The configured table must contain the columns created by the package migration.
Upgrading From Version 1
Version 2 reads existing plain and encrypted version 1 rows without modifying them. Review UPGRADING.md, then validate the conversion:
Rewrite legacy rows after the dry run succeeds:
Use --force for non-interactive production deployments and --chunk=500 to
control read batch size. The command is transactional and idempotent.
The version 1 helpers and LaravelSettings facade remain available as
deprecated compatibility wrappers. New code should use the contract or
Settings facade.
Testing
Security
Review SECURITY.md before reporting a vulnerability.
License
The MIT License. See LICENSE.md.
All versions of laravel-settings with dependencies
illuminate/cache Version ^12.60 || ^13.10
illuminate/console Version ^12.60 || ^13.10
illuminate/contracts Version ^12.60 || ^13.10
illuminate/database Version ^12.60 || ^13.10
illuminate/encryption Version ^12.60 || ^13.10
illuminate/support Version ^12.60 || ^13.10