PHPackages                             stepanenko3/laravel-helpers - 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. stepanenko3/laravel-helpers

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

stepanenko3/laravel-helpers
===========================

Helpers for laravel

v1.3.5(1y ago)71.3M↓46.4%10[1 PRs](https://github.com/stepanenko3/laravel-helpers/pulls)7MITPHPPHP &gt;=8.1CI passing

Since Aug 25Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/stepanenko3/laravel-helpers)[ Packagist](https://packagist.org/packages/stepanenko3/laravel-helpers)[ RSS](/packages/stepanenko3-laravel-helpers/feed)WikiDiscussions main Synced 3d ago

READMEChangelog (10)Dependencies (6)Versions (23)Used By (7)

Helpers for Laravel
===================

[](#helpers-for-laravel)

[![Latest Version on Packagist](https://camo.githubusercontent.com/f3bf34f5cf8335378bd0198f321bd76075a72c5148e1bff3ec798e47e1eb6876/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f73746570616e656e6b6f332f6c61726176656c2d68656c706572732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/stepanenko3/laravel-helpers)[![Total Downloads](https://camo.githubusercontent.com/b9c61a9a6d3f636a322c871b696a83e1c5734cea8c5ee58868e2995eb4ee7550/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f73746570616e656e6b6f332f6c61726176656c2d68656c706572732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/stepanenko3/laravel-helpers)[![License](https://camo.githubusercontent.com/f80a91eb50374b3674b2456044c9d86919875e89857b8150c9533dd0e14b5a9d/68747470733a2f2f706f7365722e707567782e6f72672f73746570616e656e6b6f332f6c61726176656c2d68656c706572732f6c6963656e7365)](https://packagist.org/packages/stepanenko3/laravel-helpers)

Requirements
------------

[](#requirements)

- `php: >=8.0`
- `laravel/framework: ^9.0|^10.0|^11.0

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

[](#installation)

```
# Install the package
composer require stepanenko3/laravel-helpers
```

Usage
-----

[](#usage)

Included functions:

```
apply_condition(string|int|float $amount, string|null $conditionValue = null): float

camel_to_snake_case(string $input): string

carbon(string|null $parseString = '', string $tz = null): Carbon

class_basename(mixed $class): ?string

class_by_key(string $key, string $service = 'Models'): ?string

cleanConditionValue(string|array $value): string|array

closetags(string $html): string

condition_value(string|int|float $amount, string|null $conditionValue = null): string|int|float

contrast_color(string $hexColor): string

distance(
    string|float|int $latitudeFrom,
    string|float|int $longitudeFrom,
    string|float|int $latitudeTo,
    string|float|int $longitudeTo,
    int $earthRadius = 6371000
): float|int

domain(): string

dots_to_camel_case(
    string $string,
    bool $capitalizeFirstCharacter = false
): string

formatMemory(
    float $size,
    int $level = 0,
    int $precision = 2,
    int $base = 1024,
    bool $asArray = false
): string|array

format_weight(float|int|string $weight): string

from_timestamp(string|int $timestamp): Carbon

get_ascii_key(string $needle, array $haystack = []): ?int

getAspectRatio(int $width, int $height): string

get_by_ascii(string $needle, array $haystack = []): mixed

get_initials(string $name): array|string|null

get_ip(): string

get_order_id(string|int $id): string

get_query_raw(EloquentBuilder|QueryBuilder $builder): string

hashid_decode(string|int $id): array

hashid_encode(string|int $id): string

in_array_wildcard(mixed $needle, array $haystack): bool

ipv4_in_range(mixed $ip, array|string $range): bool

ipv4_match_mask(string $ip, string $network): bool

is_day(
    string|int|null $timestamp = null,
    float $lat = 50.458124677588046,
    float $lng = 30.51755711378018
): bool

is_digit(mixed $value): bool

is_night(
    string|int|null $timestamp = null,
    float $lat = 50.458124677588046,
    float $lng = 30.51755711378018
): bool

is_query_joined(EloquentBuilder|QueryBuilder $query, string $table): bool

key_by_class(mixed $class): ?string

mb_lcfirst(string $string): string

mb_pathinfo(string $path, string $opt = ''): array|string

mb_ucfirst(string $string): string

model_by_key(string $key): ?string

natural_language_join(array $list, $conjunction = 'and'): string

normalizePrice(string|int|float $price): float

number(string|int|float $value, null|int $decimals = 0): string

num_pad(string|int $value, int $length = 8): string

plural_text(string $text, string $endings): string

// Example usage: str_plural_ru('черновик', 2, '|а|ов'); # Return: черновика
plural_word(string $word, int $count, string $endings): string

random_code_chars(bool $only_letters = false): array

random_code(int $length = 7): string

remove_query_param(string $url, string $param): string

renderBlade(string $string, array|null $data = null): false|string

rglob(string $pattern): array|false

seo_replace(string $str, array $attributes = []): string

storage_url(string $path, string|null $disk = null): string

str_contains(string $haystack, array $needles): bool

toggle_url(
    string $key,
    string|null $value = null,
    string|null $url = null
): string

translit_to_ua(string $text): string

truncate_html(string $text, int $length = 100, array $options = []): string

url_data(string $string, string $action = 'encrypt'): bool|string

user()

utf8ize(array|string $d): string

uuid(int $version = 6): string

validateDate(string $date, string $format = 'Y-m-d'): bool

valueIsPercentage(string $value): bool

valueIsToBeAdded(string $value): bool

valueIsToBeSubtracted(string $value): bool

youtube_id(string $url): string
```

Credits
-------

[](#credits)

- [Artem Stepanenko](https://github.com/stepanenko3)

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

[](#contributing)

Thank you for considering contributing to this package! Please create a pull request with your contributions with detailed explanation of the changes you are proposing.

License
-------

[](#license)

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

###  Health Score

55

—

FairBetter than 97% of packages

Maintenance69

Regular maintenance activity

Popularity47

Moderate usage in the ecosystem

Community24

Small or concentrated contributor base

Maturity66

Established project with proven stability

 Bus Factor1

Top contributor holds 76.6% 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 ~44 days

Recently: every ~89 days

Total

22

Last Release

489d ago

PHP version history (2 changes)v1.0.0PHP &gt;=8.0

v1.2.0PHP &gt;=8.1

### Community

Maintainers

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

---

Top Contributors

[![stepanenko3](https://avatars.githubusercontent.com/u/31134245?v=4)](https://github.com/stepanenko3 "stepanenko3 (36 commits)")[![makowskid](https://avatars.githubusercontent.com/u/6271194?v=4)](https://github.com/makowskid "makowskid (5 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (3 commits)")[![henergy-dev](https://avatars.githubusercontent.com/u/44502332?v=4)](https://github.com/henergy-dev "henergy-dev (1 commits)")[![negoziator](https://avatars.githubusercontent.com/u/2228675?v=4)](https://github.com/negoziator "negoziator (1 commits)")[![silentpatrik](https://avatars.githubusercontent.com/u/77385235?v=4)](https://github.com/silentpatrik "silentpatrik (1 commits)")

---

Tags

laravelhelpers

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/stepanenko3-laravel-helpers/health.svg)

```
[![Health](https://phpackages.com/badges/stepanenko3-laravel-helpers/health.svg)](https://phpackages.com/packages/stepanenko3-laravel-helpers)
```

###  Alternatives

[grumpydictator/firefly-iii

Firefly III: a personal finances manager.

23.9k69.5k](/packages/grumpydictator-firefly-iii)[knuckleswtf/scribe

Generate API documentation for humans from your Laravel codebase.✍

2.3k14.2M62](/packages/knuckleswtf-scribe)[firefly-iii/data-importer

Firefly III Data Import Tool.

8035.8k](/packages/firefly-iii-data-importer)[laravel/nightwatch

The official Laravel Nightwatch package.

36210.1M36](/packages/laravel-nightwatch)[markwalet/nova-modal-response

A Laravel Nova asset for Modal responses on an action.

17878.9k](/packages/markwalet-nova-modal-response)[ronasit/laravel-helpers

Provided helpers function and some helper class.

2085.6k31](/packages/ronasit-laravel-helpers)

PHPackages © 2026

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