junkins / prefix-registry
CakePHP PrefixRegistry
Installs: 28
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/junkins/prefix-registry
This package is auto-updated.
Last update: 2025-10-29 02:29:06 UTC
README
Introduction
You can lay Components and Helpers hierarchically.
Setup
Components
<?php namespace App\Controller\Admin; use Cake\Controller\Controller; use PrefixRegistry\Controller\PrefixComponentRegistry; class AppController extends Controller { /** * initialize */ public function initialize() { parent::initialize(); // you can use Components definded on // '/src/Controller/Component/Admin/*' OR '/src/Controller/Component/*'. $this->_components = new PrefixComponentRegistry($this); } }
Helpers
<?php namespace App\View\Admin; use Cake\View\View; use PrefixRegistry\View\PrefixHelperRegistry; class AdminView extends View { public function initialize() { parent::initialize(); // you can use Helpers definded on // '/src/View/Helper/Admin/*' OR '/src/View/Helper/*'. $this->_helpers = new PrefixHelperRegistry($this); } }