├── .gitignore ├── README.md ├── composer.json ├── composer.lock ├── config.php ├── public └── index.php ├── server.php └── src └── Server.php /.gitignore: -------------------------------------------------------------------------------- 1 | vendor 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Frog - A new way to debug in PHP 2 | 3 | There are situations where you want to show information of variables in PHP. While `print_r`, `var_dump` and `var_export` are common functions that you can use, they either output directly in your app which might affects the appearance or interrupt the process when using with `die`. It's even harder to debug when you work with Ajax or API. 4 | 5 | Until Frog! 6 | 7 | Frog creates a socket that always listen to debug requests and show the information about the variables it receives. It doesn't interrupt your process or output anything in your app. Instead it outputs data in the terminal and (optional) browser. 8 | 9 | ## Features 10 | 11 | - Simple 12 | - Supports syntax highligting when viewing the data from the browser 13 | - Supports viewing debug data in the terminal 14 | 15 | ## Installation 16 | 17 | Clone this repo 18 | 19 | ``` 20 | git clone https://github.com/rilwis/frog.git 21 | ``` 22 | 23 | Install the dependedencies with Composer 24 | 25 | ``` 26 | composer install 27 | ``` 28 | 29 | Start the socket server 30 | 31 | ``` 32 | php server.php 33 | ``` 34 | 35 | If you put Frog folder inside Lavarel Valet or inside any localhost, you can open it in the browser at `http://frog.test` (with Laravel Valet) or `http://localhost/frog/public/` (if you put Frog in your document root of localhost). 36 | 37 | After that, Frog will listen to `1503` on `127.0.0.1`. Whenever you connect via socket and send data to Frog, it will display the data in the terminal. 38 | 39 | If you open the browser, the debug info is automatically appears in the browser (without refreshing). 40 | 41 | ## Sending data to Frog 42 | 43 | Currently, we support WordPress. To send debug data from WordPress to Frog, please see [`frog-wp`](https://github.com/rilwis/frog-wp) repo. 44 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "autoload": { 3 | "psr-4": { 4 | "App\\": "src" 5 | }, 6 | "files": [ 7 | "config.php" 8 | ] 9 | }, 10 | "require": { 11 | "cboden/ratchet": "^0.4.4", 12 | "riimu/kit-phpencoder": "^2.4" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /composer.lock: -------------------------------------------------------------------------------- 1 | { 2 | "_readme": [ 3 | "This file locks the dependencies of your project to a known state", 4 | "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", 5 | "This file is @generated automatically" 6 | ], 7 | "content-hash": "3c3040eac614125409b37b15705d2ef4", 8 | "packages": [ 9 | { 10 | "name": "cboden/ratchet", 11 | "version": "v0.4.4", 12 | "source": { 13 | "type": "git", 14 | "url": "https://github.com/ratchetphp/Ratchet.git", 15 | "reference": "5012dc954541b40c5599d286fd40653f5716a38f" 16 | }, 17 | "dist": { 18 | "type": "zip", 19 | "url": "https://api.github.com/repos/ratchetphp/Ratchet/zipball/5012dc954541b40c5599d286fd40653f5716a38f", 20 | "reference": "5012dc954541b40c5599d286fd40653f5716a38f", 21 | "shasum": "" 22 | }, 23 | "require": { 24 | "guzzlehttp/psr7": "^1.7|^2.0", 25 | "php": ">=5.4.2", 26 | "ratchet/rfc6455": "^0.3.1", 27 | "react/event-loop": ">=0.4", 28 | "react/socket": "^1.0 || ^0.8 || ^0.7 || ^0.6 || ^0.5", 29 | "symfony/http-foundation": "^2.6|^3.0|^4.0|^5.0|^6.0", 30 | "symfony/routing": "^2.6|^3.0|^4.0|^5.0|^6.0" 31 | }, 32 | "require-dev": { 33 | "phpunit/phpunit": "~4.8" 34 | }, 35 | "type": "library", 36 | "autoload": { 37 | "psr-4": { 38 | "Ratchet\\": "src/Ratchet" 39 | } 40 | }, 41 | "notification-url": "https://packagist.org/downloads/", 42 | "license": [ 43 | "MIT" 44 | ], 45 | "authors": [ 46 | { 47 | "name": "Chris Boden", 48 | "email": "cboden@gmail.com", 49 | "role": "Developer" 50 | }, 51 | { 52 | "name": "Matt Bonneau", 53 | "role": "Developer" 54 | } 55 | ], 56 | "description": "PHP WebSocket library", 57 | "homepage": "http://socketo.me", 58 | "keywords": [ 59 | "Ratchet", 60 | "WebSockets", 61 | "server", 62 | "sockets", 63 | "websocket" 64 | ], 65 | "support": { 66 | "chat": "https://gitter.im/reactphp/reactphp", 67 | "issues": "https://github.com/ratchetphp/Ratchet/issues", 68 | "source": "https://github.com/ratchetphp/Ratchet/tree/v0.4.4" 69 | }, 70 | "time": "2021-12-14T00:20:41+00:00" 71 | }, 72 | { 73 | "name": "evenement/evenement", 74 | "version": "v3.0.2", 75 | "source": { 76 | "type": "git", 77 | "url": "https://github.com/igorw/evenement.git", 78 | "reference": "0a16b0d71ab13284339abb99d9d2bd813640efbc" 79 | }, 80 | "dist": { 81 | "type": "zip", 82 | "url": "https://api.github.com/repos/igorw/evenement/zipball/0a16b0d71ab13284339abb99d9d2bd813640efbc", 83 | "reference": "0a16b0d71ab13284339abb99d9d2bd813640efbc", 84 | "shasum": "" 85 | }, 86 | "require": { 87 | "php": ">=7.0" 88 | }, 89 | "require-dev": { 90 | "phpunit/phpunit": "^9 || ^6" 91 | }, 92 | "type": "library", 93 | "autoload": { 94 | "psr-4": { 95 | "Evenement\\": "src/" 96 | } 97 | }, 98 | "notification-url": "https://packagist.org/downloads/", 99 | "license": [ 100 | "MIT" 101 | ], 102 | "authors": [ 103 | { 104 | "name": "Igor Wiedler", 105 | "email": "igor@wiedler.ch" 106 | } 107 | ], 108 | "description": "Événement is a very simple event dispatching library for PHP", 109 | "keywords": [ 110 | "event-dispatcher", 111 | "event-emitter" 112 | ], 113 | "support": { 114 | "issues": "https://github.com/igorw/evenement/issues", 115 | "source": "https://github.com/igorw/evenement/tree/v3.0.2" 116 | }, 117 | "time": "2023-08-08T05:53:35+00:00" 118 | }, 119 | { 120 | "name": "guzzlehttp/psr7", 121 | "version": "2.6.2", 122 | "source": { 123 | "type": "git", 124 | "url": "https://github.com/guzzle/psr7.git", 125 | "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221" 126 | }, 127 | "dist": { 128 | "type": "zip", 129 | "url": "https://api.github.com/repos/guzzle/psr7/zipball/45b30f99ac27b5ca93cb4831afe16285f57b8221", 130 | "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221", 131 | "shasum": "" 132 | }, 133 | "require": { 134 | "php": "^7.2.5 || ^8.0", 135 | "psr/http-factory": "^1.0", 136 | "psr/http-message": "^1.1 || ^2.0", 137 | "ralouphie/getallheaders": "^3.0" 138 | }, 139 | "provide": { 140 | "psr/http-factory-implementation": "1.0", 141 | "psr/http-message-implementation": "1.0" 142 | }, 143 | "require-dev": { 144 | "bamarni/composer-bin-plugin": "^1.8.2", 145 | "http-interop/http-factory-tests": "^0.9", 146 | "phpunit/phpunit": "^8.5.36 || ^9.6.15" 147 | }, 148 | "suggest": { 149 | "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" 150 | }, 151 | "type": "library", 152 | "extra": { 153 | "bamarni-bin": { 154 | "bin-links": true, 155 | "forward-command": false 156 | } 157 | }, 158 | "autoload": { 159 | "psr-4": { 160 | "GuzzleHttp\\Psr7\\": "src/" 161 | } 162 | }, 163 | "notification-url": "https://packagist.org/downloads/", 164 | "license": [ 165 | "MIT" 166 | ], 167 | "authors": [ 168 | { 169 | "name": "Graham Campbell", 170 | "email": "hello@gjcampbell.co.uk", 171 | "homepage": "https://github.com/GrahamCampbell" 172 | }, 173 | { 174 | "name": "Michael Dowling", 175 | "email": "mtdowling@gmail.com", 176 | "homepage": "https://github.com/mtdowling" 177 | }, 178 | { 179 | "name": "George Mponos", 180 | "email": "gmponos@gmail.com", 181 | "homepage": "https://github.com/gmponos" 182 | }, 183 | { 184 | "name": "Tobias Nyholm", 185 | "email": "tobias.nyholm@gmail.com", 186 | "homepage": "https://github.com/Nyholm" 187 | }, 188 | { 189 | "name": "Márk Sági-Kazár", 190 | "email": "mark.sagikazar@gmail.com", 191 | "homepage": "https://github.com/sagikazarmark" 192 | }, 193 | { 194 | "name": "Tobias Schultze", 195 | "email": "webmaster@tubo-world.de", 196 | "homepage": "https://github.com/Tobion" 197 | }, 198 | { 199 | "name": "Márk Sági-Kazár", 200 | "email": "mark.sagikazar@gmail.com", 201 | "homepage": "https://sagikazarmark.hu" 202 | } 203 | ], 204 | "description": "PSR-7 message implementation that also provides common utility methods", 205 | "keywords": [ 206 | "http", 207 | "message", 208 | "psr-7", 209 | "request", 210 | "response", 211 | "stream", 212 | "uri", 213 | "url" 214 | ], 215 | "support": { 216 | "issues": "https://github.com/guzzle/psr7/issues", 217 | "source": "https://github.com/guzzle/psr7/tree/2.6.2" 218 | }, 219 | "funding": [ 220 | { 221 | "url": "https://github.com/GrahamCampbell", 222 | "type": "github" 223 | }, 224 | { 225 | "url": "https://github.com/Nyholm", 226 | "type": "github" 227 | }, 228 | { 229 | "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7", 230 | "type": "tidelift" 231 | } 232 | ], 233 | "time": "2023-12-03T20:05:35+00:00" 234 | }, 235 | { 236 | "name": "psr/http-factory", 237 | "version": "1.0.2", 238 | "source": { 239 | "type": "git", 240 | "url": "https://github.com/php-fig/http-factory.git", 241 | "reference": "e616d01114759c4c489f93b099585439f795fe35" 242 | }, 243 | "dist": { 244 | "type": "zip", 245 | "url": "https://api.github.com/repos/php-fig/http-factory/zipball/e616d01114759c4c489f93b099585439f795fe35", 246 | "reference": "e616d01114759c4c489f93b099585439f795fe35", 247 | "shasum": "" 248 | }, 249 | "require": { 250 | "php": ">=7.0.0", 251 | "psr/http-message": "^1.0 || ^2.0" 252 | }, 253 | "type": "library", 254 | "extra": { 255 | "branch-alias": { 256 | "dev-master": "1.0.x-dev" 257 | } 258 | }, 259 | "autoload": { 260 | "psr-4": { 261 | "Psr\\Http\\Message\\": "src/" 262 | } 263 | }, 264 | "notification-url": "https://packagist.org/downloads/", 265 | "license": [ 266 | "MIT" 267 | ], 268 | "authors": [ 269 | { 270 | "name": "PHP-FIG", 271 | "homepage": "https://www.php-fig.org/" 272 | } 273 | ], 274 | "description": "Common interfaces for PSR-7 HTTP message factories", 275 | "keywords": [ 276 | "factory", 277 | "http", 278 | "message", 279 | "psr", 280 | "psr-17", 281 | "psr-7", 282 | "request", 283 | "response" 284 | ], 285 | "support": { 286 | "source": "https://github.com/php-fig/http-factory/tree/1.0.2" 287 | }, 288 | "time": "2023-04-10T20:10:41+00:00" 289 | }, 290 | { 291 | "name": "psr/http-message", 292 | "version": "2.0", 293 | "source": { 294 | "type": "git", 295 | "url": "https://github.com/php-fig/http-message.git", 296 | "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71" 297 | }, 298 | "dist": { 299 | "type": "zip", 300 | "url": "https://api.github.com/repos/php-fig/http-message/zipball/402d35bcb92c70c026d1a6a9883f06b2ead23d71", 301 | "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71", 302 | "shasum": "" 303 | }, 304 | "require": { 305 | "php": "^7.2 || ^8.0" 306 | }, 307 | "type": "library", 308 | "extra": { 309 | "branch-alias": { 310 | "dev-master": "2.0.x-dev" 311 | } 312 | }, 313 | "autoload": { 314 | "psr-4": { 315 | "Psr\\Http\\Message\\": "src/" 316 | } 317 | }, 318 | "notification-url": "https://packagist.org/downloads/", 319 | "license": [ 320 | "MIT" 321 | ], 322 | "authors": [ 323 | { 324 | "name": "PHP-FIG", 325 | "homepage": "https://www.php-fig.org/" 326 | } 327 | ], 328 | "description": "Common interface for HTTP messages", 329 | "homepage": "https://github.com/php-fig/http-message", 330 | "keywords": [ 331 | "http", 332 | "http-message", 333 | "psr", 334 | "psr-7", 335 | "request", 336 | "response" 337 | ], 338 | "support": { 339 | "source": "https://github.com/php-fig/http-message/tree/2.0" 340 | }, 341 | "time": "2023-04-04T09:54:51+00:00" 342 | }, 343 | { 344 | "name": "ralouphie/getallheaders", 345 | "version": "3.0.3", 346 | "source": { 347 | "type": "git", 348 | "url": "https://github.com/ralouphie/getallheaders.git", 349 | "reference": "120b605dfeb996808c31b6477290a714d356e822" 350 | }, 351 | "dist": { 352 | "type": "zip", 353 | "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", 354 | "reference": "120b605dfeb996808c31b6477290a714d356e822", 355 | "shasum": "" 356 | }, 357 | "require": { 358 | "php": ">=5.6" 359 | }, 360 | "require-dev": { 361 | "php-coveralls/php-coveralls": "^2.1", 362 | "phpunit/phpunit": "^5 || ^6.5" 363 | }, 364 | "type": "library", 365 | "autoload": { 366 | "files": [ 367 | "src/getallheaders.php" 368 | ] 369 | }, 370 | "notification-url": "https://packagist.org/downloads/", 371 | "license": [ 372 | "MIT" 373 | ], 374 | "authors": [ 375 | { 376 | "name": "Ralph Khattar", 377 | "email": "ralph.khattar@gmail.com" 378 | } 379 | ], 380 | "description": "A polyfill for getallheaders.", 381 | "support": { 382 | "issues": "https://github.com/ralouphie/getallheaders/issues", 383 | "source": "https://github.com/ralouphie/getallheaders/tree/develop" 384 | }, 385 | "time": "2019-03-08T08:55:37+00:00" 386 | }, 387 | { 388 | "name": "ratchet/rfc6455", 389 | "version": "v0.3.1", 390 | "source": { 391 | "type": "git", 392 | "url": "https://github.com/ratchetphp/RFC6455.git", 393 | "reference": "7c964514e93456a52a99a20fcfa0de242a43ccdb" 394 | }, 395 | "dist": { 396 | "type": "zip", 397 | "url": "https://api.github.com/repos/ratchetphp/RFC6455/zipball/7c964514e93456a52a99a20fcfa0de242a43ccdb", 398 | "reference": "7c964514e93456a52a99a20fcfa0de242a43ccdb", 399 | "shasum": "" 400 | }, 401 | "require": { 402 | "guzzlehttp/psr7": "^2 || ^1.7", 403 | "php": ">=5.4.2" 404 | }, 405 | "require-dev": { 406 | "phpunit/phpunit": "^5.7", 407 | "react/socket": "^1.3" 408 | }, 409 | "type": "library", 410 | "autoload": { 411 | "psr-4": { 412 | "Ratchet\\RFC6455\\": "src" 413 | } 414 | }, 415 | "notification-url": "https://packagist.org/downloads/", 416 | "license": [ 417 | "MIT" 418 | ], 419 | "authors": [ 420 | { 421 | "name": "Chris Boden", 422 | "email": "cboden@gmail.com", 423 | "role": "Developer" 424 | }, 425 | { 426 | "name": "Matt Bonneau", 427 | "role": "Developer" 428 | } 429 | ], 430 | "description": "RFC6455 WebSocket protocol handler", 431 | "homepage": "http://socketo.me", 432 | "keywords": [ 433 | "WebSockets", 434 | "rfc6455", 435 | "websocket" 436 | ], 437 | "support": { 438 | "chat": "https://gitter.im/reactphp/reactphp", 439 | "issues": "https://github.com/ratchetphp/RFC6455/issues", 440 | "source": "https://github.com/ratchetphp/RFC6455/tree/v0.3.1" 441 | }, 442 | "time": "2021-12-09T23:20:49+00:00" 443 | }, 444 | { 445 | "name": "react/cache", 446 | "version": "v1.2.0", 447 | "source": { 448 | "type": "git", 449 | "url": "https://github.com/reactphp/cache.git", 450 | "reference": "d47c472b64aa5608225f47965a484b75c7817d5b" 451 | }, 452 | "dist": { 453 | "type": "zip", 454 | "url": "https://api.github.com/repos/reactphp/cache/zipball/d47c472b64aa5608225f47965a484b75c7817d5b", 455 | "reference": "d47c472b64aa5608225f47965a484b75c7817d5b", 456 | "shasum": "" 457 | }, 458 | "require": { 459 | "php": ">=5.3.0", 460 | "react/promise": "^3.0 || ^2.0 || ^1.1" 461 | }, 462 | "require-dev": { 463 | "phpunit/phpunit": "^9.5 || ^5.7 || ^4.8.35" 464 | }, 465 | "type": "library", 466 | "autoload": { 467 | "psr-4": { 468 | "React\\Cache\\": "src/" 469 | } 470 | }, 471 | "notification-url": "https://packagist.org/downloads/", 472 | "license": [ 473 | "MIT" 474 | ], 475 | "authors": [ 476 | { 477 | "name": "Christian Lück", 478 | "email": "christian@clue.engineering", 479 | "homepage": "https://clue.engineering/" 480 | }, 481 | { 482 | "name": "Cees-Jan Kiewiet", 483 | "email": "reactphp@ceesjankiewiet.nl", 484 | "homepage": "https://wyrihaximus.net/" 485 | }, 486 | { 487 | "name": "Jan Sorgalla", 488 | "email": "jsorgalla@gmail.com", 489 | "homepage": "https://sorgalla.com/" 490 | }, 491 | { 492 | "name": "Chris Boden", 493 | "email": "cboden@gmail.com", 494 | "homepage": "https://cboden.dev/" 495 | } 496 | ], 497 | "description": "Async, Promise-based cache interface for ReactPHP", 498 | "keywords": [ 499 | "cache", 500 | "caching", 501 | "promise", 502 | "reactphp" 503 | ], 504 | "support": { 505 | "issues": "https://github.com/reactphp/cache/issues", 506 | "source": "https://github.com/reactphp/cache/tree/v1.2.0" 507 | }, 508 | "funding": [ 509 | { 510 | "url": "https://opencollective.com/reactphp", 511 | "type": "open_collective" 512 | } 513 | ], 514 | "time": "2022-11-30T15:59:55+00:00" 515 | }, 516 | { 517 | "name": "react/dns", 518 | "version": "v1.12.0", 519 | "source": { 520 | "type": "git", 521 | "url": "https://github.com/reactphp/dns.git", 522 | "reference": "c134600642fa615b46b41237ef243daa65bb64ec" 523 | }, 524 | "dist": { 525 | "type": "zip", 526 | "url": "https://api.github.com/repos/reactphp/dns/zipball/c134600642fa615b46b41237ef243daa65bb64ec", 527 | "reference": "c134600642fa615b46b41237ef243daa65bb64ec", 528 | "shasum": "" 529 | }, 530 | "require": { 531 | "php": ">=5.3.0", 532 | "react/cache": "^1.0 || ^0.6 || ^0.5", 533 | "react/event-loop": "^1.2", 534 | "react/promise": "^3.0 || ^2.7 || ^1.2.1" 535 | }, 536 | "require-dev": { 537 | "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36", 538 | "react/async": "^4 || ^3 || ^2", 539 | "react/promise-timer": "^1.9" 540 | }, 541 | "type": "library", 542 | "autoload": { 543 | "psr-4": { 544 | "React\\Dns\\": "src/" 545 | } 546 | }, 547 | "notification-url": "https://packagist.org/downloads/", 548 | "license": [ 549 | "MIT" 550 | ], 551 | "authors": [ 552 | { 553 | "name": "Christian Lück", 554 | "email": "christian@clue.engineering", 555 | "homepage": "https://clue.engineering/" 556 | }, 557 | { 558 | "name": "Cees-Jan Kiewiet", 559 | "email": "reactphp@ceesjankiewiet.nl", 560 | "homepage": "https://wyrihaximus.net/" 561 | }, 562 | { 563 | "name": "Jan Sorgalla", 564 | "email": "jsorgalla@gmail.com", 565 | "homepage": "https://sorgalla.com/" 566 | }, 567 | { 568 | "name": "Chris Boden", 569 | "email": "cboden@gmail.com", 570 | "homepage": "https://cboden.dev/" 571 | } 572 | ], 573 | "description": "Async DNS resolver for ReactPHP", 574 | "keywords": [ 575 | "async", 576 | "dns", 577 | "dns-resolver", 578 | "reactphp" 579 | ], 580 | "support": { 581 | "issues": "https://github.com/reactphp/dns/issues", 582 | "source": "https://github.com/reactphp/dns/tree/v1.12.0" 583 | }, 584 | "funding": [ 585 | { 586 | "url": "https://opencollective.com/reactphp", 587 | "type": "open_collective" 588 | } 589 | ], 590 | "time": "2023-11-29T12:41:06+00:00" 591 | }, 592 | { 593 | "name": "react/event-loop", 594 | "version": "v1.5.0", 595 | "source": { 596 | "type": "git", 597 | "url": "https://github.com/reactphp/event-loop.git", 598 | "reference": "bbe0bd8c51ffc05ee43f1729087ed3bdf7d53354" 599 | }, 600 | "dist": { 601 | "type": "zip", 602 | "url": "https://api.github.com/repos/reactphp/event-loop/zipball/bbe0bd8c51ffc05ee43f1729087ed3bdf7d53354", 603 | "reference": "bbe0bd8c51ffc05ee43f1729087ed3bdf7d53354", 604 | "shasum": "" 605 | }, 606 | "require": { 607 | "php": ">=5.3.0" 608 | }, 609 | "require-dev": { 610 | "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" 611 | }, 612 | "suggest": { 613 | "ext-pcntl": "For signal handling support when using the StreamSelectLoop" 614 | }, 615 | "type": "library", 616 | "autoload": { 617 | "psr-4": { 618 | "React\\EventLoop\\": "src/" 619 | } 620 | }, 621 | "notification-url": "https://packagist.org/downloads/", 622 | "license": [ 623 | "MIT" 624 | ], 625 | "authors": [ 626 | { 627 | "name": "Christian Lück", 628 | "email": "christian@clue.engineering", 629 | "homepage": "https://clue.engineering/" 630 | }, 631 | { 632 | "name": "Cees-Jan Kiewiet", 633 | "email": "reactphp@ceesjankiewiet.nl", 634 | "homepage": "https://wyrihaximus.net/" 635 | }, 636 | { 637 | "name": "Jan Sorgalla", 638 | "email": "jsorgalla@gmail.com", 639 | "homepage": "https://sorgalla.com/" 640 | }, 641 | { 642 | "name": "Chris Boden", 643 | "email": "cboden@gmail.com", 644 | "homepage": "https://cboden.dev/" 645 | } 646 | ], 647 | "description": "ReactPHP's core reactor event loop that libraries can use for evented I/O.", 648 | "keywords": [ 649 | "asynchronous", 650 | "event-loop" 651 | ], 652 | "support": { 653 | "issues": "https://github.com/reactphp/event-loop/issues", 654 | "source": "https://github.com/reactphp/event-loop/tree/v1.5.0" 655 | }, 656 | "funding": [ 657 | { 658 | "url": "https://opencollective.com/reactphp", 659 | "type": "open_collective" 660 | } 661 | ], 662 | "time": "2023-11-13T13:48:05+00:00" 663 | }, 664 | { 665 | "name": "react/promise", 666 | "version": "v3.1.0", 667 | "source": { 668 | "type": "git", 669 | "url": "https://github.com/reactphp/promise.git", 670 | "reference": "e563d55d1641de1dea9f5e84f3cccc66d2bfe02c" 671 | }, 672 | "dist": { 673 | "type": "zip", 674 | "url": "https://api.github.com/repos/reactphp/promise/zipball/e563d55d1641de1dea9f5e84f3cccc66d2bfe02c", 675 | "reference": "e563d55d1641de1dea9f5e84f3cccc66d2bfe02c", 676 | "shasum": "" 677 | }, 678 | "require": { 679 | "php": ">=7.1.0" 680 | }, 681 | "require-dev": { 682 | "phpstan/phpstan": "1.10.39 || 1.4.10", 683 | "phpunit/phpunit": "^9.6 || ^7.5" 684 | }, 685 | "type": "library", 686 | "autoload": { 687 | "files": [ 688 | "src/functions_include.php" 689 | ], 690 | "psr-4": { 691 | "React\\Promise\\": "src/" 692 | } 693 | }, 694 | "notification-url": "https://packagist.org/downloads/", 695 | "license": [ 696 | "MIT" 697 | ], 698 | "authors": [ 699 | { 700 | "name": "Jan Sorgalla", 701 | "email": "jsorgalla@gmail.com", 702 | "homepage": "https://sorgalla.com/" 703 | }, 704 | { 705 | "name": "Christian Lück", 706 | "email": "christian@clue.engineering", 707 | "homepage": "https://clue.engineering/" 708 | }, 709 | { 710 | "name": "Cees-Jan Kiewiet", 711 | "email": "reactphp@ceesjankiewiet.nl", 712 | "homepage": "https://wyrihaximus.net/" 713 | }, 714 | { 715 | "name": "Chris Boden", 716 | "email": "cboden@gmail.com", 717 | "homepage": "https://cboden.dev/" 718 | } 719 | ], 720 | "description": "A lightweight implementation of CommonJS Promises/A for PHP", 721 | "keywords": [ 722 | "promise", 723 | "promises" 724 | ], 725 | "support": { 726 | "issues": "https://github.com/reactphp/promise/issues", 727 | "source": "https://github.com/reactphp/promise/tree/v3.1.0" 728 | }, 729 | "funding": [ 730 | { 731 | "url": "https://opencollective.com/reactphp", 732 | "type": "open_collective" 733 | } 734 | ], 735 | "time": "2023-11-16T16:21:57+00:00" 736 | }, 737 | { 738 | "name": "react/socket", 739 | "version": "v1.14.0", 740 | "source": { 741 | "type": "git", 742 | "url": "https://github.com/reactphp/socket.git", 743 | "reference": "21591111d3ea62e31f2254280ca0656bc2b1bda6" 744 | }, 745 | "dist": { 746 | "type": "zip", 747 | "url": "https://api.github.com/repos/reactphp/socket/zipball/21591111d3ea62e31f2254280ca0656bc2b1bda6", 748 | "reference": "21591111d3ea62e31f2254280ca0656bc2b1bda6", 749 | "shasum": "" 750 | }, 751 | "require": { 752 | "evenement/evenement": "^3.0 || ^2.0 || ^1.0", 753 | "php": ">=5.3.0", 754 | "react/dns": "^1.11", 755 | "react/event-loop": "^1.2", 756 | "react/promise": "^3 || ^2.6 || ^1.2.1", 757 | "react/stream": "^1.2" 758 | }, 759 | "require-dev": { 760 | "phpunit/phpunit": "^9.5 || ^5.7 || ^4.8.35", 761 | "react/async": "^4 || ^3 || ^2", 762 | "react/promise-stream": "^1.4", 763 | "react/promise-timer": "^1.10" 764 | }, 765 | "type": "library", 766 | "autoload": { 767 | "psr-4": { 768 | "React\\Socket\\": "src" 769 | } 770 | }, 771 | "notification-url": "https://packagist.org/downloads/", 772 | "license": [ 773 | "MIT" 774 | ], 775 | "authors": [ 776 | { 777 | "name": "Christian Lück", 778 | "email": "christian@clue.engineering", 779 | "homepage": "https://clue.engineering/" 780 | }, 781 | { 782 | "name": "Cees-Jan Kiewiet", 783 | "email": "reactphp@ceesjankiewiet.nl", 784 | "homepage": "https://wyrihaximus.net/" 785 | }, 786 | { 787 | "name": "Jan Sorgalla", 788 | "email": "jsorgalla@gmail.com", 789 | "homepage": "https://sorgalla.com/" 790 | }, 791 | { 792 | "name": "Chris Boden", 793 | "email": "cboden@gmail.com", 794 | "homepage": "https://cboden.dev/" 795 | } 796 | ], 797 | "description": "Async, streaming plaintext TCP/IP and secure TLS socket server and client connections for ReactPHP", 798 | "keywords": [ 799 | "Connection", 800 | "Socket", 801 | "async", 802 | "reactphp", 803 | "stream" 804 | ], 805 | "support": { 806 | "issues": "https://github.com/reactphp/socket/issues", 807 | "source": "https://github.com/reactphp/socket/tree/v1.14.0" 808 | }, 809 | "funding": [ 810 | { 811 | "url": "https://opencollective.com/reactphp", 812 | "type": "open_collective" 813 | } 814 | ], 815 | "time": "2023-08-25T13:48:09+00:00" 816 | }, 817 | { 818 | "name": "react/stream", 819 | "version": "v1.3.0", 820 | "source": { 821 | "type": "git", 822 | "url": "https://github.com/reactphp/stream.git", 823 | "reference": "6fbc9672905c7d5a885f2da2fc696f65840f4a66" 824 | }, 825 | "dist": { 826 | "type": "zip", 827 | "url": "https://api.github.com/repos/reactphp/stream/zipball/6fbc9672905c7d5a885f2da2fc696f65840f4a66", 828 | "reference": "6fbc9672905c7d5a885f2da2fc696f65840f4a66", 829 | "shasum": "" 830 | }, 831 | "require": { 832 | "evenement/evenement": "^3.0 || ^2.0 || ^1.0", 833 | "php": ">=5.3.8", 834 | "react/event-loop": "^1.2" 835 | }, 836 | "require-dev": { 837 | "clue/stream-filter": "~1.2", 838 | "phpunit/phpunit": "^9.5 || ^5.7 || ^4.8.35" 839 | }, 840 | "type": "library", 841 | "autoload": { 842 | "psr-4": { 843 | "React\\Stream\\": "src/" 844 | } 845 | }, 846 | "notification-url": "https://packagist.org/downloads/", 847 | "license": [ 848 | "MIT" 849 | ], 850 | "authors": [ 851 | { 852 | "name": "Christian Lück", 853 | "email": "christian@clue.engineering", 854 | "homepage": "https://clue.engineering/" 855 | }, 856 | { 857 | "name": "Cees-Jan Kiewiet", 858 | "email": "reactphp@ceesjankiewiet.nl", 859 | "homepage": "https://wyrihaximus.net/" 860 | }, 861 | { 862 | "name": "Jan Sorgalla", 863 | "email": "jsorgalla@gmail.com", 864 | "homepage": "https://sorgalla.com/" 865 | }, 866 | { 867 | "name": "Chris Boden", 868 | "email": "cboden@gmail.com", 869 | "homepage": "https://cboden.dev/" 870 | } 871 | ], 872 | "description": "Event-driven readable and writable streams for non-blocking I/O in ReactPHP", 873 | "keywords": [ 874 | "event-driven", 875 | "io", 876 | "non-blocking", 877 | "pipe", 878 | "reactphp", 879 | "readable", 880 | "stream", 881 | "writable" 882 | ], 883 | "support": { 884 | "issues": "https://github.com/reactphp/stream/issues", 885 | "source": "https://github.com/reactphp/stream/tree/v1.3.0" 886 | }, 887 | "funding": [ 888 | { 889 | "url": "https://opencollective.com/reactphp", 890 | "type": "open_collective" 891 | } 892 | ], 893 | "time": "2023-06-16T10:52:11+00:00" 894 | }, 895 | { 896 | "name": "riimu/kit-phpencoder", 897 | "version": "v2.4.2", 898 | "source": { 899 | "type": "git", 900 | "url": "https://github.com/Riimu/Kit-PHPEncoder.git", 901 | "reference": "72ff7825de193b272e17b228394819dbfc638e72" 902 | }, 903 | "dist": { 904 | "type": "zip", 905 | "url": "https://api.github.com/repos/Riimu/Kit-PHPEncoder/zipball/72ff7825de193b272e17b228394819dbfc638e72", 906 | "reference": "72ff7825de193b272e17b228394819dbfc638e72", 907 | "shasum": "" 908 | }, 909 | "require": { 910 | "php": ">=5.6.0" 911 | }, 912 | "type": "library", 913 | "autoload": { 914 | "psr-4": { 915 | "Riimu\\Kit\\PHPEncoder\\": "src/" 916 | } 917 | }, 918 | "notification-url": "https://packagist.org/downloads/", 919 | "license": [ 920 | "MIT" 921 | ], 922 | "authors": [ 923 | { 924 | "name": "Riikka Kalliomäki", 925 | "email": "riikka.kalliomaki@gmail.com", 926 | "homepage": "http://riimu.net" 927 | } 928 | ], 929 | "description": "Highly customizable alternative to var_export for PHP code generation", 930 | "homepage": "http://kit.riimu.net", 931 | "keywords": [ 932 | "code", 933 | "encoder", 934 | "export", 935 | "generator", 936 | "variable" 937 | ], 938 | "support": { 939 | "issues": "https://github.com/Riimu/Kit-PHPEncoder/issues", 940 | "source": "https://github.com/Riimu/Kit-PHPEncoder/tree/v2.4.2" 941 | }, 942 | "time": "2022-12-10T18:12:25+00:00" 943 | }, 944 | { 945 | "name": "symfony/deprecation-contracts", 946 | "version": "v3.4.0", 947 | "source": { 948 | "type": "git", 949 | "url": "https://github.com/symfony/deprecation-contracts.git", 950 | "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf" 951 | }, 952 | "dist": { 953 | "type": "zip", 954 | "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf", 955 | "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf", 956 | "shasum": "" 957 | }, 958 | "require": { 959 | "php": ">=8.1" 960 | }, 961 | "type": "library", 962 | "extra": { 963 | "branch-alias": { 964 | "dev-main": "3.4-dev" 965 | }, 966 | "thanks": { 967 | "name": "symfony/contracts", 968 | "url": "https://github.com/symfony/contracts" 969 | } 970 | }, 971 | "autoload": { 972 | "files": [ 973 | "function.php" 974 | ] 975 | }, 976 | "notification-url": "https://packagist.org/downloads/", 977 | "license": [ 978 | "MIT" 979 | ], 980 | "authors": [ 981 | { 982 | "name": "Nicolas Grekas", 983 | "email": "p@tchwork.com" 984 | }, 985 | { 986 | "name": "Symfony Community", 987 | "homepage": "https://symfony.com/contributors" 988 | } 989 | ], 990 | "description": "A generic function and convention to trigger deprecation notices", 991 | "homepage": "https://symfony.com", 992 | "support": { 993 | "source": "https://github.com/symfony/deprecation-contracts/tree/v3.4.0" 994 | }, 995 | "funding": [ 996 | { 997 | "url": "https://symfony.com/sponsor", 998 | "type": "custom" 999 | }, 1000 | { 1001 | "url": "https://github.com/fabpot", 1002 | "type": "github" 1003 | }, 1004 | { 1005 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1006 | "type": "tidelift" 1007 | } 1008 | ], 1009 | "time": "2023-05-23T14:45:45+00:00" 1010 | }, 1011 | { 1012 | "name": "symfony/http-foundation", 1013 | "version": "v6.4.0", 1014 | "source": { 1015 | "type": "git", 1016 | "url": "https://github.com/symfony/http-foundation.git", 1017 | "reference": "44a6d39a9cc11e154547d882d5aac1e014440771" 1018 | }, 1019 | "dist": { 1020 | "type": "zip", 1021 | "url": "https://api.github.com/repos/symfony/http-foundation/zipball/44a6d39a9cc11e154547d882d5aac1e014440771", 1022 | "reference": "44a6d39a9cc11e154547d882d5aac1e014440771", 1023 | "shasum": "" 1024 | }, 1025 | "require": { 1026 | "php": ">=8.1", 1027 | "symfony/deprecation-contracts": "^2.5|^3", 1028 | "symfony/polyfill-mbstring": "~1.1", 1029 | "symfony/polyfill-php83": "^1.27" 1030 | }, 1031 | "conflict": { 1032 | "symfony/cache": "<6.3" 1033 | }, 1034 | "require-dev": { 1035 | "doctrine/dbal": "^2.13.1|^3|^4", 1036 | "predis/predis": "^1.1|^2.0", 1037 | "symfony/cache": "^6.3|^7.0", 1038 | "symfony/dependency-injection": "^5.4|^6.0|^7.0", 1039 | "symfony/expression-language": "^5.4|^6.0|^7.0", 1040 | "symfony/http-kernel": "^5.4.12|^6.0.12|^6.1.4|^7.0", 1041 | "symfony/mime": "^5.4|^6.0|^7.0", 1042 | "symfony/rate-limiter": "^5.4|^6.0|^7.0" 1043 | }, 1044 | "type": "library", 1045 | "autoload": { 1046 | "psr-4": { 1047 | "Symfony\\Component\\HttpFoundation\\": "" 1048 | }, 1049 | "exclude-from-classmap": [ 1050 | "/Tests/" 1051 | ] 1052 | }, 1053 | "notification-url": "https://packagist.org/downloads/", 1054 | "license": [ 1055 | "MIT" 1056 | ], 1057 | "authors": [ 1058 | { 1059 | "name": "Fabien Potencier", 1060 | "email": "fabien@symfony.com" 1061 | }, 1062 | { 1063 | "name": "Symfony Community", 1064 | "homepage": "https://symfony.com/contributors" 1065 | } 1066 | ], 1067 | "description": "Defines an object-oriented layer for the HTTP specification", 1068 | "homepage": "https://symfony.com", 1069 | "support": { 1070 | "source": "https://github.com/symfony/http-foundation/tree/v6.4.0" 1071 | }, 1072 | "funding": [ 1073 | { 1074 | "url": "https://symfony.com/sponsor", 1075 | "type": "custom" 1076 | }, 1077 | { 1078 | "url": "https://github.com/fabpot", 1079 | "type": "github" 1080 | }, 1081 | { 1082 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1083 | "type": "tidelift" 1084 | } 1085 | ], 1086 | "time": "2023-11-20T16:41:16+00:00" 1087 | }, 1088 | { 1089 | "name": "symfony/polyfill-mbstring", 1090 | "version": "v1.28.0", 1091 | "source": { 1092 | "type": "git", 1093 | "url": "https://github.com/symfony/polyfill-mbstring.git", 1094 | "reference": "42292d99c55abe617799667f454222c54c60e229" 1095 | }, 1096 | "dist": { 1097 | "type": "zip", 1098 | "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229", 1099 | "reference": "42292d99c55abe617799667f454222c54c60e229", 1100 | "shasum": "" 1101 | }, 1102 | "require": { 1103 | "php": ">=7.1" 1104 | }, 1105 | "provide": { 1106 | "ext-mbstring": "*" 1107 | }, 1108 | "suggest": { 1109 | "ext-mbstring": "For best performance" 1110 | }, 1111 | "type": "library", 1112 | "extra": { 1113 | "branch-alias": { 1114 | "dev-main": "1.28-dev" 1115 | }, 1116 | "thanks": { 1117 | "name": "symfony/polyfill", 1118 | "url": "https://github.com/symfony/polyfill" 1119 | } 1120 | }, 1121 | "autoload": { 1122 | "files": [ 1123 | "bootstrap.php" 1124 | ], 1125 | "psr-4": { 1126 | "Symfony\\Polyfill\\Mbstring\\": "" 1127 | } 1128 | }, 1129 | "notification-url": "https://packagist.org/downloads/", 1130 | "license": [ 1131 | "MIT" 1132 | ], 1133 | "authors": [ 1134 | { 1135 | "name": "Nicolas Grekas", 1136 | "email": "p@tchwork.com" 1137 | }, 1138 | { 1139 | "name": "Symfony Community", 1140 | "homepage": "https://symfony.com/contributors" 1141 | } 1142 | ], 1143 | "description": "Symfony polyfill for the Mbstring extension", 1144 | "homepage": "https://symfony.com", 1145 | "keywords": [ 1146 | "compatibility", 1147 | "mbstring", 1148 | "polyfill", 1149 | "portable", 1150 | "shim" 1151 | ], 1152 | "support": { 1153 | "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0" 1154 | }, 1155 | "funding": [ 1156 | { 1157 | "url": "https://symfony.com/sponsor", 1158 | "type": "custom" 1159 | }, 1160 | { 1161 | "url": "https://github.com/fabpot", 1162 | "type": "github" 1163 | }, 1164 | { 1165 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1166 | "type": "tidelift" 1167 | } 1168 | ], 1169 | "time": "2023-07-28T09:04:16+00:00" 1170 | }, 1171 | { 1172 | "name": "symfony/polyfill-php80", 1173 | "version": "v1.28.0", 1174 | "source": { 1175 | "type": "git", 1176 | "url": "https://github.com/symfony/polyfill-php80.git", 1177 | "reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5" 1178 | }, 1179 | "dist": { 1180 | "type": "zip", 1181 | "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/6caa57379c4aec19c0a12a38b59b26487dcfe4b5", 1182 | "reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5", 1183 | "shasum": "" 1184 | }, 1185 | "require": { 1186 | "php": ">=7.1" 1187 | }, 1188 | "type": "library", 1189 | "extra": { 1190 | "branch-alias": { 1191 | "dev-main": "1.28-dev" 1192 | }, 1193 | "thanks": { 1194 | "name": "symfony/polyfill", 1195 | "url": "https://github.com/symfony/polyfill" 1196 | } 1197 | }, 1198 | "autoload": { 1199 | "files": [ 1200 | "bootstrap.php" 1201 | ], 1202 | "psr-4": { 1203 | "Symfony\\Polyfill\\Php80\\": "" 1204 | }, 1205 | "classmap": [ 1206 | "Resources/stubs" 1207 | ] 1208 | }, 1209 | "notification-url": "https://packagist.org/downloads/", 1210 | "license": [ 1211 | "MIT" 1212 | ], 1213 | "authors": [ 1214 | { 1215 | "name": "Ion Bazan", 1216 | "email": "ion.bazan@gmail.com" 1217 | }, 1218 | { 1219 | "name": "Nicolas Grekas", 1220 | "email": "p@tchwork.com" 1221 | }, 1222 | { 1223 | "name": "Symfony Community", 1224 | "homepage": "https://symfony.com/contributors" 1225 | } 1226 | ], 1227 | "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", 1228 | "homepage": "https://symfony.com", 1229 | "keywords": [ 1230 | "compatibility", 1231 | "polyfill", 1232 | "portable", 1233 | "shim" 1234 | ], 1235 | "support": { 1236 | "source": "https://github.com/symfony/polyfill-php80/tree/v1.28.0" 1237 | }, 1238 | "funding": [ 1239 | { 1240 | "url": "https://symfony.com/sponsor", 1241 | "type": "custom" 1242 | }, 1243 | { 1244 | "url": "https://github.com/fabpot", 1245 | "type": "github" 1246 | }, 1247 | { 1248 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1249 | "type": "tidelift" 1250 | } 1251 | ], 1252 | "time": "2023-01-26T09:26:14+00:00" 1253 | }, 1254 | { 1255 | "name": "symfony/polyfill-php83", 1256 | "version": "v1.28.0", 1257 | "source": { 1258 | "type": "git", 1259 | "url": "https://github.com/symfony/polyfill-php83.git", 1260 | "reference": "b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11" 1261 | }, 1262 | "dist": { 1263 | "type": "zip", 1264 | "url": "https://api.github.com/repos/symfony/polyfill-php83/zipball/b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11", 1265 | "reference": "b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11", 1266 | "shasum": "" 1267 | }, 1268 | "require": { 1269 | "php": ">=7.1", 1270 | "symfony/polyfill-php80": "^1.14" 1271 | }, 1272 | "type": "library", 1273 | "extra": { 1274 | "branch-alias": { 1275 | "dev-main": "1.28-dev" 1276 | }, 1277 | "thanks": { 1278 | "name": "symfony/polyfill", 1279 | "url": "https://github.com/symfony/polyfill" 1280 | } 1281 | }, 1282 | "autoload": { 1283 | "files": [ 1284 | "bootstrap.php" 1285 | ], 1286 | "psr-4": { 1287 | "Symfony\\Polyfill\\Php83\\": "" 1288 | }, 1289 | "classmap": [ 1290 | "Resources/stubs" 1291 | ] 1292 | }, 1293 | "notification-url": "https://packagist.org/downloads/", 1294 | "license": [ 1295 | "MIT" 1296 | ], 1297 | "authors": [ 1298 | { 1299 | "name": "Nicolas Grekas", 1300 | "email": "p@tchwork.com" 1301 | }, 1302 | { 1303 | "name": "Symfony Community", 1304 | "homepage": "https://symfony.com/contributors" 1305 | } 1306 | ], 1307 | "description": "Symfony polyfill backporting some PHP 8.3+ features to lower PHP versions", 1308 | "homepage": "https://symfony.com", 1309 | "keywords": [ 1310 | "compatibility", 1311 | "polyfill", 1312 | "portable", 1313 | "shim" 1314 | ], 1315 | "support": { 1316 | "source": "https://github.com/symfony/polyfill-php83/tree/v1.28.0" 1317 | }, 1318 | "funding": [ 1319 | { 1320 | "url": "https://symfony.com/sponsor", 1321 | "type": "custom" 1322 | }, 1323 | { 1324 | "url": "https://github.com/fabpot", 1325 | "type": "github" 1326 | }, 1327 | { 1328 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1329 | "type": "tidelift" 1330 | } 1331 | ], 1332 | "time": "2023-08-16T06:22:46+00:00" 1333 | }, 1334 | { 1335 | "name": "symfony/routing", 1336 | "version": "v6.4.1", 1337 | "source": { 1338 | "type": "git", 1339 | "url": "https://github.com/symfony/routing.git", 1340 | "reference": "0c95c164fdba18b12523b75e64199ca3503e6d40" 1341 | }, 1342 | "dist": { 1343 | "type": "zip", 1344 | "url": "https://api.github.com/repos/symfony/routing/zipball/0c95c164fdba18b12523b75e64199ca3503e6d40", 1345 | "reference": "0c95c164fdba18b12523b75e64199ca3503e6d40", 1346 | "shasum": "" 1347 | }, 1348 | "require": { 1349 | "php": ">=8.1", 1350 | "symfony/deprecation-contracts": "^2.5|^3" 1351 | }, 1352 | "conflict": { 1353 | "doctrine/annotations": "<1.12", 1354 | "symfony/config": "<6.2", 1355 | "symfony/dependency-injection": "<5.4", 1356 | "symfony/yaml": "<5.4" 1357 | }, 1358 | "require-dev": { 1359 | "doctrine/annotations": "^1.12|^2", 1360 | "psr/log": "^1|^2|^3", 1361 | "symfony/config": "^6.2|^7.0", 1362 | "symfony/dependency-injection": "^5.4|^6.0|^7.0", 1363 | "symfony/expression-language": "^5.4|^6.0|^7.0", 1364 | "symfony/http-foundation": "^5.4|^6.0|^7.0", 1365 | "symfony/yaml": "^5.4|^6.0|^7.0" 1366 | }, 1367 | "type": "library", 1368 | "autoload": { 1369 | "psr-4": { 1370 | "Symfony\\Component\\Routing\\": "" 1371 | }, 1372 | "exclude-from-classmap": [ 1373 | "/Tests/" 1374 | ] 1375 | }, 1376 | "notification-url": "https://packagist.org/downloads/", 1377 | "license": [ 1378 | "MIT" 1379 | ], 1380 | "authors": [ 1381 | { 1382 | "name": "Fabien Potencier", 1383 | "email": "fabien@symfony.com" 1384 | }, 1385 | { 1386 | "name": "Symfony Community", 1387 | "homepage": "https://symfony.com/contributors" 1388 | } 1389 | ], 1390 | "description": "Maps an HTTP request to a set of configuration variables", 1391 | "homepage": "https://symfony.com", 1392 | "keywords": [ 1393 | "router", 1394 | "routing", 1395 | "uri", 1396 | "url" 1397 | ], 1398 | "support": { 1399 | "source": "https://github.com/symfony/routing/tree/v6.4.1" 1400 | }, 1401 | "funding": [ 1402 | { 1403 | "url": "https://symfony.com/sponsor", 1404 | "type": "custom" 1405 | }, 1406 | { 1407 | "url": "https://github.com/fabpot", 1408 | "type": "github" 1409 | }, 1410 | { 1411 | "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", 1412 | "type": "tidelift" 1413 | } 1414 | ], 1415 | "time": "2023-12-01T14:54:37+00:00" 1416 | } 1417 | ], 1418 | "packages-dev": [], 1419 | "aliases": [], 1420 | "minimum-stability": "stable", 1421 | "stability-flags": [], 1422 | "prefer-stable": false, 1423 | "prefer-lowest": false, 1424 | "platform": [], 1425 | "platform-dev": [], 1426 | "plugin-api-version": "2.3.0" 1427 | } 1428 | -------------------------------------------------------------------------------- /config.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Frog 8 | 9 | 10 | 11 | 12 | 40 | 41 | 42 |

Listening...

43 |
44 | 45 |
46 | 47 | 48 |
49 | 50 | 51 | 117 | 118 | -------------------------------------------------------------------------------- /server.php: -------------------------------------------------------------------------------- 1 | run(); -------------------------------------------------------------------------------- /src/Server.php: -------------------------------------------------------------------------------- 1 | encoder = new PHPEncoder; 15 | $this->clients = new SplObjectStorage; 16 | } 17 | 18 | public function onOpen( ConnectionInterface $connection ) { 19 | $this->clients->attach( $connection ); 20 | } 21 | 22 | public function onMessage( ConnectionInterface $from, $message ) { 23 | $variables = json_decode( $message, true ); 24 | 25 | // First parameter is the caller in format $file:$line. 26 | $caller = array_shift( $variables ); 27 | 28 | // Output to terminal. 29 | $output = []; 30 | foreach ( $variables as $variable ) { 31 | $output[] = $this->encoder->encode( $variable ); 32 | } 33 | echo "\n", implode( "\n\n", [ 34 | str_repeat( '-', 40 ), 35 | "# $caller", 36 | implode( "\n\n", $output ), 37 | ] ), "\n"; 38 | 39 | // Output to the browser. 40 | $output = []; 41 | foreach ( $variables as $variable ) { 42 | $output[] = $this->encoder->encode( $variable ); 43 | } 44 | $output = "$caller###" . implode( "\n\n", $output ); 45 | foreach ( $this->clients as $client ) { 46 | if ( $from !== $client ) { 47 | $client->send( $output ); 48 | } 49 | } 50 | } 51 | 52 | public function onClose( ConnectionInterface $connection ) { 53 | $this->clients->detach( $connection ); 54 | } 55 | 56 | public function onError( ConnectionInterface $connection, Exception $e ) { 57 | $connection->close(); 58 | } 59 | } --------------------------------------------------------------------------------