Skip to content
This repository was archived by the owner on Dec 1, 2021. It is now read-only.

phork/microphork-package-debug

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This is a simple debugging package for the microphork framework. The debug class is a dispatcher. The display handler outputs the debugging data and the log handler logs it to a file.

To extend this package create a \Phork\App\Debug class in the app/classes folder and an app/config/debug.php file to define the active handler(s).

Usage

//load and initialize a new debug package
$class = \Phork::instance()->initPackage('Debug');
$debug = new $class();

//get the loaded config
$config = \Phork::config()->get('debug');

//initialize the debug handler
if ($config->handlers && $handlers = $config->handlers->export()) {
    $debug->init($handlers);
}

//send some debugging data
$debug->log('this', 'will', 'be', 'concatenated');

Credits

Built by Elenor at Phork Labs.

License

Licensed under The MIT License http://www.opensource.org/licenses/mit-license.php

About

A simple debugging package for the microphork framework.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages