2017 © Pedro Peláez
 

library jade-phalcon

HAML-like template engine for phalcon

image

kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 7 Versions
  • 3 % Grown

The README.md

pug-phalcon

Pug Template Engine for Phalcon, (*1)

To use Pug with your Phalcon application, just add to composer.json, in the require section:, (*2)

"pug-php/pug-phalcon": "^1.0"

Or use the command line:, (*3)

composer require pug-php/pug-phalcon

Then register the template:, (*4)

require '../vendor/autoload.php';

// ...
$di = new FactoryDefault();

// Setting up the view component
$di['view'] = function() {
    $view = new View();
    $view->setViewsDir('../app/views/');
    $view->registerEngines(array(
        ".pug" => function($view, $di) {
            return new \Phalcon\Mvc\View\Engine\Pug($view, $di, array(
                'cache' => '/tmp/myproject/pug',
                'prettyprint' => APP_ENV == 'development',
            ));
        }
    ));

    return $view;
};

Now you can add pug files in the views directory:, (*5)

app/views/index.pug:, (*6)

doctype html
html
  head
    title pug-phalcon
  body
    p Generetad with pug-phalcon

The Versions

23/06 2016

dev-master

9999999-dev https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade pug phalcon minification

23/06 2016

1.0.0

1.0.0.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade pug phalcon minification

09/12 2015

0.1.4

0.1.4.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade phalcon minification

04/04 2015

0.1.3

0.1.3.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade phalcon minification

04/04 2015

0.1.2

0.1.2.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade phalcon minification

04/04 2015

0.1.1

0.1.1.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade phalcon minification

03/04 2015

0.1.0

0.1.0.0 https://github.com/kylekatarnls/jade-phalcon

HAML-like template engine for phalcon

  Sources   Download

MIT

The Requires

 

template jade phalcon minification