PHPackages                             yuyue8/tp\_driver - 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. [Framework](/categories/framework)
4. /
5. yuyue8/tp\_driver

ActiveLibrary[Framework](/categories/framework)

yuyue8/tp\_driver
=================

thinkphp driver

1.0.3(2y ago)0171Apache-2.0PHPPHP &gt;=8.0.2

Since Jun 1Pushed 2y ago1 watchersCompare

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

READMEChangelog (2)Dependencies (1)Versions (5)Used By (1)

TpDriver
========

[](#tpdriver)

安装
--

[](#安装)

```
composer require yuyue8/tp_driver

```

使用流程
----

[](#使用流程)

创建 `driver` 类

```
只创建基类
php think make:driver /app/driver/pay

创建基类和策略类
php think make:driver /app/driver/pay ali

```

创建时会默认创建一个跟基础类同名的config文件，可以在文件中设置默认的策略类和其他配置

目录格式为：

```
pay
    -storage
        -Ali.php
    -BasePay.php
    -Pay.php

```

可以在`BasePay`中定义策略类必须实现的方法：

```
abstract public function send(string $phone);

```

使用如下： 使用默认策略类：

```
$pay = new Pay();
$pay->send('123456');
```

使用其他策略类：

```
$pay = new Pay('ali');
$pay->send('123456');
```

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

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

Total

4

Last Release

800d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/53282d9e2a3bfccaf3b02ed4e2f1ede03c83141441299709b10a47d6392cc25a?d=identicon)[yuyue8](/maintainers/yuyue8)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/yuyue8-tp-driver/health.svg)

```
[![Health](https://phpackages.com/badges/yuyue8-tp-driver/health.svg)](https://phpackages.com/packages/yuyue8-tp-driver)
```

###  Alternatives

[topthink/think

the new thinkphp framework

8.0k1.2M13](/packages/topthink-think)[topthink/think-swoole

Swoole extend for thinkphp

477174.4k19](/packages/topthink-think-swoole)[topthink/think-throttle

throttle middleware for thinkphp8

18993.1k2](/packages/topthink-think-throttle)[jaguarjack/catchadmin

The CatchAdmin Background management

8962.6k](/packages/jaguarjack-catchadmin)[topthink/think-multi-app

thinkphp multi app support

26813.1k50](/packages/topthink-think-multi-app)

PHPackages © 2026

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