lendable/twig-bundle
最新稳定版本:v2.0.1
Composer 安装命令:
composer require lendable/twig-bundle
包简介
load twig templates from the database
README 文档
README
TwigBundle
Symfony bundle that allows Twig templates to be loaded from database store.
Install
composer require lendable/twig-bundle
Require the bundle in your AppKernel.php
<?php class YourAppKernel extends \Symfony\Component\HttpKernel\Kernel { public function registerBundles(): array { $bundles = [ // ... new Alpha\TwigBundle\AlphaTwigBundle(), ]; return $bundles; } // ... }
You can use the provided Template entity or use your own. Overwrite the bundle entity with setting paramater values for your entity class alpha_twig.entity.template.class and the directory containing its YAML mapping alpha_twig.entity.template.mapping_dir.
// your-application/app/config/config.yml parameters: alpha_twig.entity.template.class: 'Alpha\TwigBundle\Entity\Template' alpha_twig.entity.template.mapping_dir: 'src/Resources/config/doctrine'
License
统计信息
- 总下载量: 19.83k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-02-26