Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shyim/php-dump-client
https://github.com/shyim/php-dump-client
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/shyim/php-dump-client
- Owner: shyim
- Created: 2021-01-12T23:24:06.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2021-12-16T14:24:06.000Z (almost 3 years ago)
- Last Synced: 2024-06-02T20:33:43.311Z (6 months ago)
- Language: PHP
- Size: 61.5 KB
- Stars: 2
- Watchers: 5
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PHP Dump Client
This is Symfony Var-Dump Server in fancy. This repository holds the code for the PHP Client to send informations to the UI Server.
## This is project is currently in work
## Install
```bash
composer req shyim/php-dump-client
```or Prefixed (Without requiring other dependencies)
```bash
composer req shyim/php-dump-client-prefixed
```or `auto_prepend_file` globally useable
* Clone `shyim/php-dump-client-prefixed` somewhere
* Configure `auto_prepend_file=PREFIXED_FOLDER/prepend.php`## Usage
* Start the [Debug Server first](https://github.com/shyim/php-dump-server)
* Optional: Set environment `PHP_DUMP_SERVER_URL` to the Dump Server if the dump server runs not local
* Use your favourite `pd()` Command```php
// Sends variables to the UI Server to show
pd()->log($var1, $var2);// Sends the trace to the UI
pd()->trace();// Clears the ui window
pd()->clear();// Stops the process until its unlocked in the UI
pd()->pause();// Show execution time of function and memory usage
pd()->time('Label', function() {
sleep(1);
});// Show execution time of function and memory usage
$timer = pd()->time('Label');// Do something
$timer->stop();
// Allows tagging of calls in the UI
pd()->tag('My-Tag')->Method($args);
```