PHPackages                             naroat/ivory - 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. naroat/ivory

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

naroat/ivory
============

Ivory是一个实用、高效和可重用的PHP语言工具包。帮助开发者更加高效地开发PHP应用。

v1.0.3(1y ago)2311MITPHPPHP &gt;=7.2

Since Dec 4Pushed 1y ago1 watchersCompare

[ Source](https://github.com/naroat/ivory)[ Packagist](https://packagist.org/packages/naroat/ivory)[ RSS](/packages/naroat-ivory/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (3)Used By (1)

English | [中文](./README_zh-CN.md)

[![](./docs/assets/images/logo-512x512.png)](./docs/assets/images/logo-512x512.png)

[![PHP version](https://camo.githubusercontent.com/7fe5e9f79fc1d389e5ee6889399d57b96cbfdfb4dc0ea57aa6868ba37060e577/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253345253344372e322d626c7565)](https://camo.githubusercontent.com/7fe5e9f79fc1d389e5ee6889399d57b96cbfdfb4dc0ea57aa6868ba37060e577/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253345253344372e322d626c7565)[![Composer version](https://camo.githubusercontent.com/0701e44f78e2e2a8dce95ac9c3b3c1bbc862c45770e277dba5209b460f010ef9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f6d706f7365722d253345253344322e302d6f72616e6765)](https://camo.githubusercontent.com/0701e44f78e2e2a8dce95ac9c3b3c1bbc862c45770e277dba5209b460f010ef9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f6d706f7365722d253345253344322e302d6f72616e6765)[![License](https://camo.githubusercontent.com/c312c651e2e7910423230d9c8c6e525350baad7001ea6ba6af8b41af7bcd49b9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d64646f646765722e737667)](https://github.com/naroat/ivory/blob/main/LICENSE)

What is Ivory?
--------------

[](#what-is-ivory)

Ivory is a practical, efficient and reusable PHP function toolkit. Help developers develop PHP applications more efficiently. The tools included in Ivory are:

- String
- Array
- Data &amp; Time
- Cryptor
- File
- Network
- validator

Documentation：

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

[](#installation)

Version requirements：

- PHP &gt;= 7.2
- composer &gt;= 2.0

Installation:

```
composer require naroat/ivory
```

Use
---

[](#use)

Example: Find the number of days between two dates：

```
$startDate = '2024-10-03';
$endDate = '2024-12-10';
$res = \Naroat\Ivory\DateTime\DateTime::dateDiff($startDate, $endDate);
var_dump($res);
//output:
//int(68)
```

Example: Example of a private email

```
$res = \Naroat\Ivory\Str\Str::hideEmail('foo123456@bar.com');
var_dump($res);
//output: "foo***@bar.com"

$res = \Naroat\Ivory\Str\Str::hideEmail('foo123456@bar.com', '---@');
var_dump($res);
//output: "foo---@bar.com"
```

More
----

[](#more)

For more features, please refer to [API](zh-cn/api/string.md).

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance44

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 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

Unknown

Total

1

Last Release

530d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/698e7e4a16333353987ded991b1ebb4ff60b993f4d41939ade6f038d60193118?d=identicon)[taoran1401](/maintainers/taoran1401)

---

Top Contributors

[![naroat](https://avatars.githubusercontent.com/u/22391562?v=4)](https://github.com/naroat "naroat (18 commits)")

---

Tags

libraryphpphp-helperutilsphphelperpackagelibraryutilkitivory

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/naroat-ivory/health.svg)

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

###  Alternatives

[nguyenanhung/codeigniter-basic-helper

CodeIgniter - Basic Helper

1027.3k1](/packages/nguyenanhung-codeigniter-basic-helper)

PHPackages © 2026

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