PHPackages                             softpulze/laravibe-standards - 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. softpulze/laravibe-standards

ActiveLibrary

softpulze/laravibe-standards
============================

Standard conventions, structure, and tooling for Laravel apps built the LaraVibe way.

v0.2.0(today)25↑2900%MITPHPPHP ^8.4CI passing

Since Jul 23Pushed todayCompare

[ Source](https://github.com/softpulze/laravibe-standards)[ Packagist](https://packagist.org/packages/softpulze/laravibe-standards)[ Docs](https://github.com/softpulze/laravibe-standards)[ GitHub Sponsors](https://github.com/softpulze)[ RSS](/packages/softpulze-laravibe-standards/feed)WikiDiscussions main Synced today

READMEChangelog (2)Dependencies (9)Versions (3)Used By (0)

Laravibe Standards
==================

[](#laravibe-standards)

 [![Packagist](https://camo.githubusercontent.com/21d86292d7d81ff8a3df6e9b634c2344377656e3957f80b14f8731c572127610/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f736f667470756c7a652f6c617261766962652d7374616e64617264732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/softpulze/laravibe-standards) [![PHP from Packagist](https://camo.githubusercontent.com/c87bc01ac449b5d726991eafd53c296079d08eb4b206ea22390a20aa72441bc1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f736f667470756c7a652f6c617261766962652d7374616e64617264732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/softpulze/laravibe-standards) [![Laravel versions](https://camo.githubusercontent.com/c15eb6147a7044264bd0f8715bea08ff6170a9f270ba4a25735e9a919c664258/68747470733a2f2f62616467652e6c61726176656c2e636c6f75642f62616467652f736f667470756c7a652f6c617261766962652d7374616e64617264733f7374796c653d666c6174)](https://packagist.org/packages/softpulze/laravibe-standards) [![GitHub Workflow Status (main)](https://camo.githubusercontent.com/85fb5113c8e59b06de7c4d436b88b2318edcbd69024690ea2defc6a14913f4c0/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f736f667470756c7a652f6c617261766962652d7374616e64617264732f74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d5465737473267374796c653d666c61742d737175617265)](https://github.com/softpulze/laravibe-standards/actions) [![Total Downloads](https://camo.githubusercontent.com/09e6186056e02d425b08334416ef114a78d634a49ceefb8067d844a54a629cc1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f736f667470756c7a652f6c617261766962652d7374616e64617264732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/softpulze/laravibe-standards)

Standard conventions, structure, and tooling for Laravel apps built the LaraVibe way.

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

[](#installation)

You can install the package via Composer:

```
composer require softpulze/laravibe-standards
```

You may publish all of the package's resources at once:

```
php artisan vendor:publish --tag="laravibe-standards"
```

Or, you may publish each resource individually:

### Publishing the Configuration File

[](#publishing-the-configuration-file)

```
php artisan vendor:publish --tag="laravibe-standards-config"
```

### Publishing Stubs

[](#publishing-stubs)

```
php artisan vendor:publish --tag="laravibe-standards-stubs"
```

Usage
-----

[](#usage)

### DTOs (Data Transfer Objects)

[](#dtos-data-transfer-objects)

Laravibe Standards provides a convention for defining immutable, typed DTOs with automatic hydration and serialization.

**Generate a DTO:**

```
php artisan make:dto UserProfileDTO
php artisan make:dto Account/UpdateProfileDTO
```

**Define a DTO:**

```
final readonly class UserProfileDTO implements Arrayable, Jsonable
{
    use \SoftPulze\LaravibeStandards\DTOs\Concerns\AsDTO;

    public function __construct(
        public string $name,
        public ?string $bio = null,
    ) {
    }
}
```

**Hydrate and serialize:**

```
$dto = UserProfileDTO::from($request);
$dto = UserProfileDTO::fromArray(['name' => 'Alice', 'bio' => 'Developer']);

$array = $dto->toArray();
$json  = $dto->toJson();
$data  = $dto->toEloquent();

$updated = $dto->with(['bio' => 'Senior Dev']);
```

See the [full DTO guide](src/DTOs/README.md) for conventions, type casting, and advanced usage.

### Enums

[](#enums)

Laravibe Standards provides a shared `HasEnumMetadata` trait with label, option, and validation helpers for backed and unit enums.

**Generate an enum:**

```
php artisan make:enum ToastType --string
php artisan make:enum Priority
```

**Define an enum:**

```
enum ToastType: string
{
    use \SoftPulze\LaravibeStandards\Enums\Concerns\HasEnumMetadata;

    case Error = 'error';
    case Success = 'success';
    case Warning = 'warning';
    case Info = 'info';
}
```

**Use helpers:**

```
ToastType::options();    // [{name: 'Error', value: 'error', label: 'Error'}, ...]
ToastType::values();     // ['error', 'success', 'warning', 'info']
ToastType::isValidValue('success');  // true
ToastType::fromValueOrFail('error'); // ToastType::Error
ToastType::Error->label();           // 'Error'
```

See the [full enum guide](src/Enums/README.md) for conventions, the concern contract, and design rules.

### Resources

[](#resources)

Laravibe Standards provides base resource classes for API and Inertia responses with reusable field helpers.

**Generate a resource:**

```
php artisan make:resource UserResource
php artisan make:resource UserCollection --collection
```

**Define a resource:**

```
final class UserResource extends \SoftPulze\LaravibeStandards\Resources\AppResource
{
    public function toArray(Request $request): array
    {
        return [
            $this->id(),
            $this->attribute('name'),
            $this->attribute('email'),
            ...$this->timestamps(),
        ];
    }
}
```

**Use in controllers:**

```
UserResource::make($user);                           // single
UserResource::collection(User::paginate());          // paginated

// Inertia
return inertia('users/Show', ['user' => UserResource::make($user)->toInertia()]);
```

See the [full resource guide](src/Resources/README.md) for helpers, conventions, and serialization rules.

Changelog
---------

[](#changelog)

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

Contributing
------------

[](#contributing)

Thank you for considering contributing to Laravibe Standards! Please review our [contributing guide](.github/CONTRIBUTING.md) to get started.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](.github/SECURITY.md) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Ashok Barua Akas](https://github.com/softpulze)
- [All Contributors](../../contributors)

License
-------

[](#license)

Laravibe Standards is open-sourced software licensed under the [MIT license](LICENSE.md).

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance100

Actively maintained with recent releases

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 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 ~0 days

Total

2

Last Release

0d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/55571706?v=4)[Ashok](/maintainers/ashokbaruaakas)[@ashokbaruaakas](https://github.com/ashokbaruaakas)

---

Top Contributors

[![ashokbaruaakas](https://avatars.githubusercontent.com/u/55571706?v=4)](https://github.com/ashokbaruaakas "ashokbaruaakas (7 commits)")

---

Tags

laravelsoftpulzelaravibe-standards

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/softpulze-laravibe-standards/health.svg)

```
[![Health](https://phpackages.com/badges/softpulze-laravibe-standards/health.svg)](https://phpackages.com/packages/softpulze-laravibe-standards)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3345.3M347](/packages/psalm-plugin-laravel)[api-platform/laravel

API Platform support for Laravel

58174.6k17](/packages/api-platform-laravel)

PHPackages © 2026

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