tentwofour/symfony-twig-bridge

Symfony implementation of the tentwofour/twig package

1.1.2 2022-01-24 16:04 UTC

This package is auto-updated.

Last update: 2024-04-24 20:51:11 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