schranz-templating / spiral-mustache-integration
通过mustache模板引擎将模板渲染器集成到spiral中。
0.1.0
2022-11-14 21:24 UTC
Requires
- php: ^7.2 || ^8.0
- schranz-templating/mustache-adapter: ^0.1
- spiral/boot: ^3.0
- spiral/config: ^3.0
- spiral/core: ^3.0
README
将Mustache Adapter集成到Spiral框架中。
是Schranz Templating Project的一部分。
安装
通过Composer安装此包
composer require schranz-templating/spiral-mustache-integration
如果框架未自动添加,请在您的app/src/Application/Kernel.php
中注册Bootloader类
class Kernel extends \Spiral\Framework\Kernel { protected const LOAD = [ // ... \Schranz\Templating\Integration\Spiral\Mustache\Bootloader\MustacheBootloader::class, ]; }
配置
此集成提供了以下配置。
// app/config/schranz_templating_mustache.php declare(strict_types=1); return [ 'path' => 'app/views', 'cache_dir' => 'runtime/cache/cache', ];