【文件属性】:
文件名称:LiTE:轻量级模板引擎
文件大小:33KB
文件格式:ZIP
更新时间:2021-02-17 12:02:58
lightweight template-engine native php71 ad-hoc
立特
李ghtweight牛逼emplateËngine
描述
LiTE是特别适用于后端的临时模板引擎。 它是本机的,因为它使用PHP作为其模板语言,并且不需要编译模板。 它支持模板变量和视图助手。
要求
LiTE需要PHP 7.3+
安装
通过作曲家
$ composer require tpawl/lite
用法
开发者专用
基本
LiTE的核心是一个称为模板表达式的对象(类TPawl\LiTE\Expressions\TemplateExpression )。
模板表达式对象创建如下:
$ settings = [
$ template , // a string holding the template
[ 'the' => 'variables' , 'go' => 'here' ],
'/path/to/view_helpers' ,
'vi
【文件预览】:
LiTE-master
----.coveralls.yml(37B)
----src()
--------Context()
--------Factories()
--------Expressions()
--------Filter()
--------Php()
--------ViewHelperInterface.php(316B)
--------Version.php(354B)
--------Interpreter()
--------Miscellaneous()
--------String()
--------Exceptions()
--------ErrorHandlers()
--------Assertion()
--------Variable()
--------FileSystem()
----.travis.yml(519B)
----LICENSE(1KB)
----phpunit.xml(491B)
----README.md(6KB)
----.editorconfig(312B)
----tests()
--------StringTypeTest.php(623B)
--------SubTemplateExpressionTest.php(3KB)
--------AssertionTest.php(1KB)
--------TemplateInterpreterTest.php(959B)
--------TemplateExpressionTest.php(8KB)
--------ContextTest.php(3KB)
--------FileSystemTest.php(781B)
--------FilterTest.php(1KB)
--------Asset()
--------bootstrap.php(435B)
--------VariableFunctionsTest.php(487B)
----.gitignore(23B)
----composer.json(795B)