tentwofour/symfony-twig-bridge

Symfony implementation of the tentwofour/twig package

1.0.3 2017-03-30 07:52 UTC

README

Bridge to provide Twig extensions (https://github.com/tentwofour/twig) into Symfony2.

Enable in AppKernel

class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            ...
            new Ten24\SymfonyTwigBridgeBundle\Ten24SymfonyTwigBridgeBundle()
        )
        ...
    }
    ...
}

Usage

By default, the bundle registers all extensions from https://github.com/tentwofour/twig by default. See that bundle for extension documentation.

Any/all extensions can be disabled via bundle configuration:

# app/config.yml

ten24_twig:
    email: false
    diff: false
    inflector: false
    money: false
    number: false