定制 netrivet/wp-event-emitter 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

netrivet/wp-event-emitter

最新稳定版本:6.0.0

Composer 安装命令:

composer require netrivet/wp-event-emitter

包简介

An object oriented event emitter for WordPress actions

README 文档

README

An object oriented event emitter for WordPress actions

Motivation

A familiar event interface that delegates to the global add_action and do_action functions of WordPress. It also presents a much more testable interface as it only uses the WP functions if they are available.

Methods

on

Delegate to WordPress' add_action function. In test environments a local collection of listeners will be used.

emit

Delegate to WordPress' do_action function. In test environments a local collection of listeners will be used.

filter

Delegate to WordPress' add_filter function. In test environments a local collection of listeners will be used.

applyFilters

Delegate to WordPress' apply_filters function. In test environments a local collection of listeners will be used.

Tests

Tests use PHPUnit

$ vendor/bin/phpunit

统计信息

  • 总下载量: 20.25k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 19
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 16
  • Watchers: 5
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-06-01