{"repo":"torchlight-api/torchlight-commonmark-php","free":true,"listed":false,"github":"https://github.com/torchlight-api/torchlight-commonmark-php","clone":"git clone https://github.com/torchlight-api/torchlight-commonmark-php.git","description":"A Commonmark PHP extension for Torchlight - the syntax highlighting API.","language":"PHP","stars":28,"topics":["commonmark","torchlight","laravel","markdown","syntax-highlighter","syntax-highlighting"],"license":"MIT","category":"productivity","readme_excerpt":"Laravel Torchlight Extension for Commonmark 📚 The full docs can be found at torchlight.dev/docs/clients/commonmark-php. A Torchlight syntax highlighting extension for the PHP League's Commonmark Markdown Parser in a Laravel application. Supports both CommonMark version 1 and version 2. Torchlight is a VS Code-compatible syntax highlighter that requires no JavaScript, supports every language, every VS Code theme, line highlighting, git diffing, and more. Installation To install, require the package from composer: This will install the Laravel Client as well. Adding the Extension If you are using Graham Campbell's Laravel Markdown package, you can add the extension in your markdown.php file, under the \"extensions\" key. If you aren't using the Laravel Markdown package, you can add the extension manually: That's all you need to do! All of your code fences will now be highlighted via Torchlight. Configuration Once the package is downloaded, you can run the following command to publish your configuration file: Once run, you should see a new file torchlight.php in you config folder, with contents that look like this: Cache Set the cache driver that Torchlight will use. Theme You can change the theme of all your code blocks by adjusting the theme key in your configuration. Token This is your API token from torchlight.dev. (Torchlight is completely free for personal and open source projects.) Blade Components By default Torchlight works by using a custom Laravel component. If you'd l","default_branch":null,"files":null,"tree":[],"storefront":"/r/torchlight-api","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/torchlight-api/torchlight-commonmark-php/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}