PHPackages                             decodelabs/enlighten - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. decodelabs/enlighten

ActiveLibrary

decodelabs/enlighten
====================

PHP source highlighter

v0.9.4(9mo ago)121.7k↓100%1MITPHPPHP ^8.4CI passing

Since Sep 30Pushed 3mo ago2 watchersCompare

[ Source](https://github.com/decodelabs/enlighten)[ Packagist](https://packagist.org/packages/decodelabs/enlighten)[ RSS](/packages/decodelabs-enlighten/feed)WikiDiscussions develop Synced today

READMEChangelog (10)Dependencies (3)Versions (21)Used By (1)

Enlighten
=========

[](#enlighten)

[![PHP from Packagist](https://camo.githubusercontent.com/7700b1a081689f2f8b74282ef6dc2bedf50d6eb6dc8c2de6f34489b61fe1eeb9/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6465636f64656c6162732f656e6c69676874656e3f7374796c653d666c6174)](https://packagist.org/packages/decodelabs/enlighten)[![Latest Version](https://camo.githubusercontent.com/fb4706dedd5727d6d820c80f10814ee7ddb04c9bddb55785bf699d91b95cabe7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6465636f64656c6162732f656e6c69676874656e2e7376673f7374796c653d666c6174)](https://packagist.org/packages/decodelabs/enlighten)[![Total Downloads](https://camo.githubusercontent.com/4bb9a26e2520563f67afde6fd372302c3838f84526f185ff99b0160242b9c877/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6465636f64656c6162732f656e6c69676874656e2e7376673f7374796c653d666c6174)](https://packagist.org/packages/decodelabs/enlighten)[![GitHub Workflow Status](https://camo.githubusercontent.com/7e3c3f3a4b9b8c35af7cebe2d9a7c3a63598ff3abcee40393e324790bf381fe3/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6465636f64656c6162732f656e6c69676874656e2f696e746567726174652e796d6c3f6272616e63683d646576656c6f70)](https://github.com/decodelabs/enlighten/actions/workflows/integrate.yml)[![PHPStan](https://camo.githubusercontent.com/e25c14ce011edabdd0fbd2e10415b41cc5d66ed11ef3e5b7edd074c5bdd35a2d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d656e61626c65642d3434434331312e7376673f6c6f6e6743616368653d74727565267374796c653d666c6174)](https://github.com/phpstan/phpstan)[![License](https://camo.githubusercontent.com/11a614f79ae2c4eaa9cf85de749e8309572792229597190d80b4596241c8f00c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6465636f64656c6162732f656e6c69676874656e3f7374796c653d666c6174)](https://packagist.org/packages/decodelabs/enlighten)

### PHP source highlighter

[](#php-source-highlighter)

Enlighten provides exhaustive and accurate PHP source highlighting for use in debugging systems.

---

Installation
------------

[](#installation)

This package requires PHP 8.4 or higher.

Install via Composer:

```
composer require decodelabs/enlighten
```

Usage
-----

[](#usage)

Enlighten uses the PHP tokenizer extension which requires the full source from file (including `
