PHPackages                             hauyzi/yaf-init - 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. hauyzi/yaf-init

ActiveProject[Framework](/categories/framework)

hauyzi/yaf-init
===============

The Yaf Framework.

22PHP

Since Jul 25Pushed 2y agoCompare

[ Source](https://github.com/hayuzi/yaf-init)[ Packagist](https://packagist.org/packages/hauyzi/yaf-init)[ RSS](/packages/hauyzi-yaf-init/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

yaf-init
========

[](#yaf-init)

> yaf的初始化框架，便于调用

### 1. 基础目录结构

[](#1-基础目录结构)

```
- application
    |- controllers              默认模块控制器
    |- library                  自动加载的类库
    |- models                   默认的model类目录
    |- modules                  模块目录
    |   |-
    |- plugins                  插件目录
    |- views                    模板文件
    |- Bootstrap.php            框架默认启动初始化文件
- conf
    |- application.ini          配置文件
    |- application.ini.sample   配置文件示例（将项目拉下来后拷贝修改即可）
- public
    |- cli.php                  控制台脚本执行入口
    |- index.php                web执行入口
- vendor                        composer类库目录

```

### 2. 封装扩展的内容

[](#2-封装扩展的内容)

#### 2.1 基础调整

[](#21-基础调整)

- 在Bootstrap中统一禁用了模版渲染
- 采用控制器应对action的方式 (yaf的控制器命名只能第一个字母大写)

#### 2.1 封装了基础 model 类

[](#21-封装了基础-model-类)

Model类采用 [Medoo](https://github.com/catfan/Medoo), 该类是基于PDO的封装, 但是非ORM形式，因而处理关联数据可能稍微有些不便。

#### 2.2 控制器封装

[](#22-控制器封装)

TODO

#### 2.3 路由与请求

[](#23-路由与请求)

TODO

#### 2.4 其他的功能库

[](#24-其他的功能库)

##### 2.4.1 基于pcntl与posix的多进程业务处理封装

[](#241-基于pcntl与posix的多进程业务处理封装)

请参考 AppCore\\Concurrency\\Sample\\SampleReactor来处理

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity38

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/b85cdcbee65e1bd8edfe3e881726fb8da3185b2063036a48ab8be3f702ff5bbc?d=identicon)[hayuzi](/maintainers/hayuzi)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/hauyzi-yaf-init/health.svg)

```
[![Health](https://phpackages.com/badges/hauyzi-yaf-init/health.svg)](https://phpackages.com/packages/hauyzi-yaf-init)
```

###  Alternatives

[laravel/telescope

An elegant debug assistant for the Laravel framework.

5.2k67.8M190](/packages/laravel-telescope)[laravel/passport

Laravel Passport provides OAuth2 server support to Laravel.

3.4k85.0M529](/packages/laravel-passport)[spiral/roadrunner

RoadRunner: High-performance PHP application server and process manager written in Go and powered with plugins

8.4k12.2M84](/packages/spiral-roadrunner)[nolimits4web/swiper

Most modern mobile touch slider and framework with hardware accelerated transitions

41.8k177.2k1](/packages/nolimits4web-swiper)[laravel/dusk

Laravel Dusk provides simple end-to-end testing and browser automation.

1.9k36.7M255](/packages/laravel-dusk)[laravel/prompts

Add beautiful and user-friendly forms to your command-line applications.

708181.8M591](/packages/laravel-prompts)

PHPackages © 2026

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