PHPackages                             laragrad/codifier - 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. laragrad/codifier

ActivePackage

laragrad/codifier
=================

v1.2.2(4y ago)08MITPHPPHP ^7.2|^8.0

Since May 20Pushed 4y ago1 watchersCompare

[ Source](https://github.com/laragrad/codifier)[ Packagist](https://packagist.org/packages/laragrad/codifier)[ RSS](/packages/laragrad-codifier/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (6)DependenciesVersions (7)Used By (0)

laragrad/codifier
=================

[](#laragradcodifier)

This package provides a service that enable to use any project config data as dictionary of codes with multilanguage support and cache using.

Installing
----------

[](#installing)

Run command in console

```
composer require laragrad/codifier

```

Add next lines into your `config/app.php`

```
$providers => [
	...
	\Laragrad\Codifier\CodifierServiceProvider::class,
],

$aliases => [
	...
	'Codifier' => \Laragrad\Codifier\CodifierServiceFacade::class,
],

```

Run command in console

```
php artisan vendor:publish

```

and type choise number to publish `\Laragrad\Codifier\CodifierServiceProvider`

Will be published next files:

- `/config/laragrad/codifier/config.php` - Package configuration
- `/config/laragrad/codifier/example.php` - Example codifier data
- `/resources/lang/vendor/laragrad/codifier/en/messages.php` - Package messages
- `/resources/lang/vendor/laragrad/codifier/en/example.php` - Example codifier translations

Configurating
-------------

[](#configurating)

See package configuration example in file `/config/laragrad/codifier/config.php`.

There are two root elements

- **use\_cache** - A boolean option for enable or disable cache using.
- **sections** - An array of codifier section configurations.

### Section configuration

[](#section-configuration)

Section configuration must have next options

- **data\_path** - a path to config consisted section data
- **trans\_base\_path** - a base path to the lang translation resource
- **handler** - handler class name

Codifier facade methods
-----------------------

[](#codifier-facade-methods)

### get()

[](#get)

Returns section element or full data.

```
get(string $section, string|null $path, string|null $locale) : array

```

Arguments:

- **$section** - Section name.
- **$path** - Path to section element. If it is NULL then returns full section data.
- **$locale** - Locale code. If it is NULL then current locale.

### getSection()

[](#getsection)

Returns one section data.

```
getSection(string $section, string|null $locale) : array

```

Arguments:

- **$section** - Section name.
- **$locale** - Locale code. If it is NULL then current locale.

### getSections()

[](#getsections)

Returns array of many of all sections.

```
getSections(array|null $sections, string|null $locale) : array

```

Arguments:

- **$sections** - Array of section names. If it is NULL then all configured sections.
- **$locale** - Locale code. If it is NULL then current locale.

### cache()

[](#cache)

Warm cache keys if cache using enabled in configuration.

```
cache(array|string|null $sections, array|string|null $locales) : array

```

Arguments:

- **$sections** - One section name or array of section names. If it is NULL then all configured sections.
- **$locales** - One locale code or array of locale codes. If it is NULL then all configured locales.

Returns list of messages.

### clear()

[](#clear)

Clear cache keys if cache using enabled in configuration.

```
clear(array|string|null $sections, array|string|null $locales) : array

```

Arguments:

- **$sections** - One section name or array of section names. If it is NULL then all configured sections.
- **$locales** - One locale code or array of locale codes. If it is NULL then all configured locales.

Returns list of messages.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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.

###  Release Activity

Cadence

Every ~95 days

Recently: every ~119 days

Total

6

Last Release

1710d ago

PHP version history (2 changes)v1.0PHP ^7.2.0

v1.2.2PHP ^7.2|^8.0

### Community

Maintainers

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

---

Top Contributors

[![laragrad](https://avatars.githubusercontent.com/u/65588602?v=4)](https://github.com/laragrad "laragrad (2 commits)")

---

Tags

laravelcodifier

### Embed Badge

![Health badge](/badges/laragrad-codifier/health.svg)

```
[![Health](https://phpackages.com/badges/laragrad-codifier/health.svg)](https://phpackages.com/packages/laragrad-codifier)
```

###  Alternatives

[rtconner/laravel-likeable

Trait for Laravel Eloquent models to allow easy implementation of a 'like' or 'favorite' or 'remember' feature.

394388.0k5](/packages/rtconner-laravel-likeable)[hemp/presenter

Easy Model Presenters in Laravel

247592.6k1](/packages/hemp-presenter)[slowlyo/owl-admin

基于 laravel、amis 开发的后台框架~

61214.2k26](/packages/slowlyo-owl-admin)

PHPackages © 2026

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