PHPackages                             nova-kit/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. [Database &amp; ORM](/categories/database)
4. /
5. nova-kit/helpers

ActiveLibrary[Database &amp; ORM](/categories/database)

nova-kit/helpers
================

Useful helpers for Laravel Nova

v1.0.1(2y ago)6224MITPHPPHP ^7.3 || ^8.0

Since Apr 10Pushed 2y ago1 watchersCompare

[ Source](https://github.com/nova-kit/helpers)[ Packagist](https://packagist.org/packages/nova-kit/helpers)[ Fund](https://paypal.me/crynobone)[ Fund](https://liberapay.com/crynobone)[ RSS](/packages/nova-kit-helpers/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (10)Dependencies (3)Versions (13)Used By (0)

Useful helpers for Laravel Nova
===============================

[](#useful-helpers-for-laravel-nova)

[![tests](https://github.com/nova-kit/helpers/workflows/tests/badge.svg?branch=master)](https://github.com/nova-kit/helpers/actions?query=workflow%3Atests+branch%3Amaster)[![Latest Stable Version](https://camo.githubusercontent.com/2dba3a368aa2c231d79dba395f0c8ab773f8678dad89c96eaeb71afa83e1dba0/68747470733a2f2f706f7365722e707567782e6f72672f6e6f76612d6b69742f68656c706572732f762f737461626c65)](https://packagist.org/packages/nova-kit/helpers)[![Total Downloads](https://camo.githubusercontent.com/d76638a970230c227b3e4f2768d85831d05ef1353e334343aaea2c2ebe935393/68747470733a2f2f706f7365722e707567782e6f72672f6e6f76612d6b69742f68656c706572732f646f776e6c6f616473)](https://packagist.org/packages/nova-kit/helpers)[![Latest Unstable Version](https://camo.githubusercontent.com/b057fb79c037db4757b78ce43dea00eb8e352dfc81f7fe041750e745b220796f/68747470733a2f2f706f7365722e707567782e6f72672f6e6f76612d6b69742f68656c706572732f762f756e737461626c65)](https://packagist.org/packages/nova-kit/helpers)[![License](https://camo.githubusercontent.com/0d1a070653fdf9a918d21abc5e523202d4cb7d29dbcfc2e416880b353389151f/68747470733a2f2f706f7365722e707567782e6f72672f6e6f76612d6b69742f68656c706572732f6c6963656e7365)](https://packagist.org/packages/nova-kit/helpers)[![Coverage Status](https://camo.githubusercontent.com/da75784255f9d852a1d5e107f49562cfc181596f3ca4c0122d189af1dd3e21a0/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f6e6f76612d6b69742f68656c706572732f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/nova-kit/helpers?branch=master)

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

[](#installation)

To install through composer, run the following command from terminal:

```
composer require "nova-kit/helpers"
```

Usages
------

[](#usages)

### Eloquent

[](#eloquent)

#### Get Qualified Column Name

[](#get-qualified-column-name)

```
NovaKit\column_name(string|\Illuminate\Database\Eloquent\Model $model, string $attribute): string;
```

The function generate qualified column name for an eloquent model:

```
use function NovaKit\column_name;

return column_name(App\Models\User::class, 'email');
```

#### Eloquent Exists

[](#eloquent-exists)

```
NovaKit\eloquent_exists(\Illuminate\Database\Eloquent\Model|mixed $model): bool;
```

The function checks if given `$model` is an instance of `Illuminate\Database\Eloquent\Model` and it exists in the database:

```
use App\Models\User;
use function NovaKit\eloquent_exists;

$user = User::find(5);

return eloquent_exists($user);
```

#### Get Table Name

[](#get-table-name)

```
NovaKit\table_name(string|\Illuminate\Database\Eloquent\Model $model): string;
```

The function generate table name for an eloquent model:

```
use function NovaKit\table_name;

return table_name(App\Models\User::class);
```

### Nova Request Helpers

[](#nova-request-helpers)

#### Has Ordering

[](#has-ordering)

```
NovaKit\has_ordering(\Laravel\Nova\Http\Requests\NovaRequest $request): bool;
```

Determine if current Request has any ordering.

```
use Laravel\Nova\Http\Requests\NovaRequest;
use function NovaKit\has_ordering;

public static function indexQuery(NovaRequest $request, $query)
{
    if (! has_ordering($request)) {
        $query->orderBy('name');
    }
}
```

#### Running Action

[](#running-action)

```
NovaKit\running_action(\Illuminate\Http\Request $request, ?string $action): bool;
```

Determine NovaRequest is currently Running an Action Request.

```
use Illuminate\Http\Request;
use Laravel\Nova\Http\Requests\NovaRequest;

public function authorizedToUpdate(Request $request)
{
    if (running_action($request, 'open-on-platform')) {
        return $request->user()->canModerateResources();
    }

    return $this->authorizedTo($request, 'update');
}
```

### Common Helpers

[](#common-helpers)

#### Validate Column Name

[](#validate-column-name)

```
NovaKit\is_column_name(mixed $column): bool;
```

Validate if given `$column` is a valid column name.

```
use function NovaKit\is_column_name;

if (is_column_name($request->query('sortBy'))) {
    $query->latest($request->query('sortBy'));
}
```

#### Safe Integer

[](#safe-integer)

```
NovaKit\safe_int(mixed $value): int|string;
```

Convert large id higher than JavaScript's `Number.MAX_SAFE_INTEGER` to string.

```
use function NovaKit\safe_int;

return safe_int(9007199254741001); // will return "9007199254741001"
```

#### Schemaless URL

[](#schemaless-url)

```
NovaKit\schemaless_url(string $url): string;
```

Get schemaless URL for given `$url`

```
use function NovaKit\schemaless_url;

return schemaless_url('https://github.com'); // will return "github.com"
```

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity64

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

Recently: every ~95 days

Total

12

Last Release

1041d ago

Major Versions

v0.4.5 → v1.0.02023-03-08

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/172966?v=4)[Mior Muhammad Zaki](/maintainers/crynobone)[@crynobone](https://github.com/crynobone)

---

Top Contributors

[![crynobone](https://avatars.githubusercontent.com/u/172966?v=4)](https://github.com/crynobone "crynobone (69 commits)")

---

Tags

eloquentlaravellaravel-nova

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/nova-kit-helpers/health.svg)

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

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k115.1M102](/packages/jdorn-sql-formatter)[illuminate/database

The Illuminate Database package.

2.8k52.4M9.4k](/packages/illuminate-database)[ramsey/uuid-doctrine

Use ramsey/uuid as a Doctrine field type.

90440.3M211](/packages/ramsey-uuid-doctrine)[reliese/laravel

Reliese Components for Laravel Framework code generation.

1.7k3.4M16](/packages/reliese-laravel)[wildside/userstamps

Laravel Userstamps provides an Eloquent trait which automatically maintains `created\_by` and `updated\_by` columns on your model, populated by the currently authenticated user in your application.

7511.7M13](/packages/wildside-userstamps)

PHPackages © 2026

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