2017 © Pedro PelĂĄez
 

library templating-service-provider

Template engine implementation using PHP or Twig for Silex

image

sergiors/templating-service-provider

Template engine implementation using PHP or Twig for Silex

  • Friday, July 29, 2016
  • by sergiors
  • Repository
  • 2 Watchers
  • 1 Stars
  • 42,218 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 10 Versions
  • 5 % Grown

The README.md

Templating Service Provider

A service to help you with template engine implementation using PHP or Twig., (*1)

Install

composer require sergiors/templating-service-provider
use Sergiors\Silex\Provider\TemplatingServiceProvider;

$app->register(new TemplatingServiceProvider(), [
    'templating.paths' => '__DIR__.'/../Resources/views/%name%' // or an array
]);

$app['templating']->render(/.../);

If you want to use Twig:, (*2)

use Silex\Provider\TwigServiceProvider;
use Sergiors\Silex\Provider\TemplatingServiceProvider;

$app->register(new TwigServiceProvider(), [
    'twig.path' => __DIR__.'/../Resources/views'
]);
$app->register(new TemplatingServiceProvider());

$app['templating']->render(/.../);

Don't forget to install twig/twig and symfony/twig-bridge to use the Twig., (*3)

License

MIT, (*4)

The Versions

28/01 2016
22/09 2015

1.1.0

1.1.0.0

Template engine implementation using PHP or Twig for Silex

  Sources   Download

MIT

The Requires

 

The Development Requires

by SĂ©rgio Rafael Siqueira

16/09 2015

1.0.0

1.0.0.0

Template engine implementation using PHP or Twig for Silex

  Sources   Download

MIT

The Requires

 

The Development Requires

by SĂ©rgio Rafael Siqueira