Easy php module storage collector for small project
dev-master | 1.0.1 |
---|---|
Embed the script without change the core.
just like as add-ons, plugins or whatever it names.
- Php 7.0 or later
- Php tokenizer extension enabled
- `spl` enabled
- function `eval` allowed (for validate php file - optional)
<?php
use Pentagonal\Modular\Reader;
$reader = new Reader('/Path/To/Directory');
$reader->configure();
$modules = $reader->getValidModules();
// init all module
foreach ($modules as $moduleIdentifier => $module) {
// initialize per module
// this only called once on module base
$module->finalInitOnce();
}
MIT LICENSE