PHPackages                             magdkudama/twig-highlight - 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. [Templating &amp; Views](/categories/templating)
4. /
5. magdkudama/twig-highlight

ActiveLibrary[Templating &amp; Views](/categories/templating)

magdkudama/twig-highlight
=========================

Twig extension to highlight content

19PHP

Since Nov 12Pushed 11y ago1 watchersCompare

[ Source](https://github.com/magdkudama/twig-highlight)[ Packagist](https://packagist.org/packages/magdkudama/twig-highlight)[ RSS](/packages/magdkudama-twig-highlight/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Twig highlight extension
========================

[](#twig-highlight-extension)

[![Build Status](https://camo.githubusercontent.com/135b89481ad01d91612426d2c2742891c64620e20ee4b649fedd53b049828bc2/68747470733a2f2f7472617669732d63692e6f72672f6d6167646b7564616d612f747769672d686967686c696768742e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/magdkudama/twig-highlight)

Simple extension to highlight code (it could be done using a filter or a function, of course... but why not with a custom tag? :D).

Installing
----------

[](#installing)

Add the dependency to the `composer.json` file:

```
{
    "require": {
        "magdkudama/twig-highlight": "dev-master"
    }
}
```

A minimum working version:

```
