5ichong/yaf-twig
最新稳定版本:v0.0.3
Composer 安装命令:
composer require 5ichong/yaf-twig
包简介
Yaf framework using Twig is template engine
README 文档
README
Yaf using Twig is template engine
Installation
To install Validator, simply:
$ composer require 5ichong/yaf-twig
For latest commit version:
$ composer require 5ichong/yaf-twig @dev
Requirements
Validator works with 7.0, 7.1.
Quick Start and Examples
Add to application.ini:
[product] application.view.ext = html [devel : product] application.twig.debug = true
Add to index.php:
require __DIR__ . '/vendor/autoload.php';
Add to Bootstrap.php
use Yaf\Application; use Yaf\Dispatcher; public function _initView(Dispatcher $dispatcher) { $conf = Application::app()->getConfig(); $options = !empty($conf->twig) ? $conf->twig->toArray() : []; $twig = new \Aichong\Twig(APP_PATH . "/views/", $options); $dispatcher->setView($twig); }
统计信息
- 总下载量: 2.78k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2017-06-21