PHPackages                             jackminh/tinypng - 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. [Image &amp; Media](/categories/media)
4. /
5. jackminh/tinypng

ActiveLibrary[Image &amp; Media](/categories/media)

jackminh/tinypng
================

An awesome tinypng library

00HTML

Since Dec 21Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/jackminh/tinypng)[ Packagist](https://packagist.org/packages/jackminh/tinypng)[ RSS](/packages/jackminh-tinypng/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

### 压缩图片

[](#压缩图片)

本库是基于laravel进行封将装的组件库, 功能是使用api进行图片压缩,可以单个图片，也可以传图片所在的目录进行批量压缩

### tinypng APK

[](#tinypng-apk)

使用此项目进行压缩图片时需要先到 申请app key 1.在网站填写full name和email，点击Get your API key按钮 2.email会收到一条邮件，点击可以获取到app key 3.每个app key每个月可以免费压缩500张图片

### 测试

[](#测试)

此项目完成单元测试 ...

### 安装使用

[](#安装使用)

1. 使用composer 安装
2. composer require jackminh/tinypng:@dev
3. 在 laravel项目中执行

```
  php artisan vendor:publish --provider="Vendor\\Jackminh\\Tinypng\\TinypngServiceProvider"

```

执行完发布操作后在laravel项目下的config会有一个tinypng.php配置文件

### 使用

[](#使用)

```
use Jackminh\Tinypng\Facades\Tinypng;

$file_name="/home/vagrant/code/images/a.jpeg";

$dist_file_name="/home/vagrant/code/images/a_a.jpeg";

Tinypng::handlerPic($file_name, $dist_file_name);

```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance50

Moderate activity, may be stable

Popularity0

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity14

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.

### Community

Maintainers

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

---

Top Contributors

[![jackminh](https://avatars.githubusercontent.com/u/12270859?v=4)](https://github.com/jackminh "jackminh (9 commits)")

### Embed Badge

![Health badge](/badges/jackminh-tinypng/health.svg)

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

###  Alternatives

[milon/barcode

Barcode generator like Qr Code, PDF417, C39, C39+, C39E, C39E+, C93, S25, S25+, I25, I25+, C128, C128A, C128B, C128C, 2-Digits UPC-Based Extention, 5-Digits UPC-Based Extention, EAN 8, EAN 13, UPC-A, UPC-E, MSI (Variation of Plessey code)

1.5k13.3M39](/packages/milon-barcode)[bkwld/croppa

Image thumbnail creation through specially formatted URLs for Laravel

510496.0k23](/packages/bkwld-croppa)[goat1000/svggraph

Generates SVG graphs

132849.6k3](/packages/goat1000-svggraph)[cohensive/embed

Media Embed (for Laravel or as a standalone).

120370.4k](/packages/cohensive-embed)[netresearch/rte-ckeditor-image

Image support in CKEditor for the TYPO3 ecosystem - by Netresearch

63991.3k4](/packages/netresearch-rte-ckeditor-image)[humanmade/tachyon-plugin

Rewrites WordPress image URLs to use Tachyon

87338.5k2](/packages/humanmade-tachyon-plugin)

PHPackages © 2026

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