Media\Twig\Extension

Overview

Extension for Twig used by the Media module

Extends
  • Twig\Extension\AbstractExtension
Implements
  • Twig\Extension\ExtensionInterface

Public Methods

public getFilters()

public getFilters(): array 

getFilters returns a list of filters this extensions provides.

public getFunctions()

public getFunctions(): array 

getFunctions returns a list of functions to add to the existing list.

public getTokenParsers()

public getTokenParsers(): array 

getTokenParsers returns a list of token parsers this extensions provides.

public mediaFilter()

public mediaFilter(mixed $file): string 

mediaFilter converts supplied file to a URL relative to the media library.

Show inherited public methods

Inherited Public Methods

  • getNodeVisitors() - (defined in Twig\Extension\AbstractExtension)
  • getOperators() - (defined in Twig\Extension\AbstractExtension)
  • getTests() - (defined in Twig\Extension\AbstractExtension)