PHPackages                             anibalsanchez/create-pattern - 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. anibalsanchez/create-pattern

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

anibalsanchez/create-pattern
============================

A lightweight PHP implementation of the Static Create Pattern using a trait.

3.0.0(4mo ago)21.6k—0%MITPHPPHP ^7.4 || ^8.0

Since May 25Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/anibalsanchez/create-pattern)[ Packagist](https://packagist.org/packages/anibalsanchez/create-pattern)[ RSS](/packages/anibalsanchez-create-pattern/feed)WikiDiscussions master Synced today

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

Create Pattern
==============

[](#create-pattern)

Description
-----------

[](#description)

A lightweight PHP implementation of the Static Create Pattern using a trait.

`composer require anibalsanchez/create-pattern`

Inspired by [byjg/SingletonPatternPHP](https://github.com/byjg/SingletonPatternPHP)

Usage
-----

[](#usage)

### Create your class

[](#create-your-class)

```
require "vendor/autoload.php";

class Example
{
    // You need to use the trait here
    use \Extly\Infrastructure\Creator\CreatorTrait;
    use \Extly\Infrastructure\Creator\SingletonTrait;

    // Put your code below
}
```

### Use your class

[](#use-your-class)

```
$example = Example::create();
```

```
$example = Example::getInstance();
```

Install
-------

[](#install)

Just type: `composer require anibalsanchez/create-pattern`

References
----------

[](#references)

- [https://en.wikipedia.org/wiki/Singleton\_pattern](https://en.wikipedia.org/wiki/Singleton_pattern)

License
-------

[](#license)

The MIT License (MIT)

###  Health Score

47

—

FairBetter than 94% of packages

Maintenance75

Regular maintenance activity

Popularity18

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity71

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

Total

5

Last Release

133d ago

Major Versions

1.0.0 → 2.0.02018-05-29

2.2.0 → 3.0.02025-11-08

PHP version history (2 changes)2.2.0PHP ^7.3 || ^8.0

3.0.0PHP ^7.4 || ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/df7fbcf5652e2a22940918d3c4db48cfaadd50c9096fd7ccd46504d62eb6fd07?d=identicon)[anibal.sanchez](/maintainers/anibal.sanchez)

---

Top Contributors

[![anibalsanchez](https://avatars.githubusercontent.com/u/385780?v=4)](https://github.com/anibalsanchez "anibalsanchez (11 commits)")

### Embed Badge

![Health badge](/badges/anibalsanchez-create-pattern/health.svg)

```
[![Health](https://phpackages.com/badges/anibalsanchez-create-pattern/health.svg)](https://phpackages.com/packages/anibalsanchez-create-pattern)
```

PHPackages © 2026

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