Skip to content
This repository has been archived by the owner on May 5, 2019. It is now read-only.

jbboehr/handlebars.php

Repository files navigation

handlebars.php

Build Status Coverage Status Latest Stable Version License

PHP handlebars.js Compiler and VM. Use with handlebars.c and php-handlebars.

Deprecated: Use php-handlebars instead

Requirements

php-handlebars

Install

Via Composer

composer require jbboehr/handlebars

Usage

$handlebars = new Handlebars\Handlebars();

$fn = $handlebars->compile('{{foo}}');
echo $fn(array(
    'foo' => 'bar',
));

echo $handlebars->render('{{foo}}', array(
    'foo' => 'bar',
));

Testing

make test

License

This project is licensed under the LGPLv3. handlebars.js is licensed under the MIT license.