TwigExtension::setDateFormatter

public TwigExtension::setDateFormatter(DateFormatterInterface $date_formatter)

Sets the date formatter.

Parameters

\Drupal\Core\Datetime\DateFormatter $date_formatter: The date formatter.

Return value

$this

File

core/lib/Drupal/Core/Template/TwigExtension.php, line 115

Class

TwigExtension
A class providing Drupal Twig extensions.

Namespace

Drupal\Core\Template

Code

public function setDateFormatter(DateFormatterInterface $date_formatter) {
  $this->dateFormatter = $date_formatter;
  return $this;
}
doc_Drupal
2016-10-29 09:49:42
Comments
Leave a Comment

Please login to continue.