PHPackages                             jamesbhatta/app-settings - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. jamesbhatta/app-settings

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

jamesbhatta/app-settings
========================

Store application settings on the fly.

32051PHP

Since May 9Pushed 4y ago1 watchersCompare

[ Source](https://github.com/jamesbhatta/app-settings)[ Packagist](https://packagist.org/packages/jamesbhatta/app-settings)[ RSS](/packages/jamesbhatta-app-settings/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

APP SETTINGS (Laravel)
======================

[](#app--settings-laravel)

Store application settings in database on the fly.

> With the help of this package you can persist the settings to database and cache it for performance gain with zero queries.

Installation
------------

[](#installation)

1. You can install the package via composer:

    ```
    composer require jamesbhatta/app-settings
    ```
2. Optional: The service provider will automatically get registered. Or you may manually add the service provider in your `config/app.php` file:

    ```
    'providers' => [
    	 // ...
    	 JamesBhatta\AppSettings\AppSettingServiceProvider::class,
    ],
    "aliases" => [
    	// ...
    	'AppSetting' => JamesBhatta\AppSettings\Facades\AppSetting::class
    ]

    ```
3. To create the `jb_app_settings` table, you must publish the migration and run it with:

    ```
    php artisan vendor:publish --provider="JamesBhatta\AppSettings\AppSettingServiceProvider" --tag="migrations"

    php artisan migrate
    ```

Using It
--------

[](#using-it)

```
// save new setting
appSettings()->set('key', 'value');

// get setting
appSettings()->get('key');

// get all settings
appSettings()->allSettings();

// get fresh settings directly from database
appSettings()->allSettings($fresh = true);

// save multiple values at once
appSettings()->set([
	'key_one' => 'value_one',
	'key_two' => 'value_two',
	'key_three' => 'value_three'
]);

// check if setting exists
appSettings()->has('key'); // returns true/false

// remove a setting
appsettings()->remove('key');  // returns true on success

// get setting or default value if not exist
appSettings()->get('key', 'default value');

// ofcourse you can use facade
use JamesBhatta\AppSettings\Facades\AppSetting;
AppSettings::set('key', 'value');
```

Testing
-------

[](#testing)

```
$ composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information about what has changed recently.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [James Bhatta](https://github.com/jamesbhatta)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity26

Early-stage or recently created project

 Bus Factor1

Top contributor holds 94.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/dd6966d430111a9de2dc8ec875f62e4afde759b01fff1dddbf81873ecc5296fb?d=identicon)[jamesbhattta](/maintainers/jamesbhattta)

---

Top Contributors

[![jamesbhatta](https://avatars.githubusercontent.com/u/24622175?v=4)](https://github.com/jamesbhatta "jamesbhatta (16 commits)")[![bobknob23987](https://avatars.githubusercontent.com/u/5871865?v=4)](https://github.com/bobknob23987 "bobknob23987 (1 commits)")

### Embed Badge

![Health badge](/badges/jamesbhatta-app-settings/health.svg)

```
[![Health](https://phpackages.com/badges/jamesbhatta-app-settings/health.svg)](https://phpackages.com/packages/jamesbhatta-app-settings)
```

###  Alternatives

[adrhumphreys/silverstripe-textdropdownfield

A text field combined with a dropdown field.

106.1k](/packages/adrhumphreys-silverstripe-textdropdownfield)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
