Skip to content

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TwigPad

Software License Total Downloads

Lib for add symbols to start or end of string in Twig templates.

Install

composer require zhukmax/twigpad

Usage

Basic example:

<?php

require_once 'vendor/autoload.php';

$loader = new Twig_Loader_Array(array(
    'index' => 'Hello {{ rightpad(name, 9, "#") }}',
));

$twig = new Twig_Environment($loader);
$twig->addExtension(new Zhukmax\TwigPad\TwigPad());

echo $twig->render('index', array('name' => 'Max'));
// => Hello Max######

About

Lib for add symbols to start or end of string in Twig templates.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages