Yii View Rendering Library
This library provides templates rendering abstraction supporting layout-view-subview hierarchy, custom renderers with PHP-based as default and more. It is used in Yii Framework but is supposed to be usable separately.
- PHP 7.4 or higher.
The package could be installed via composer:
composer require yiisoft/view --prefer-dist
The package provides two use cases for managing view templates:
- Basic functionality for use in any environment.
- Advanced functionality for use in a WEB environment.
- yiisoft/yii-view - a wrapper that is used in Yii Framework. Adds additional functionality for a WEB environment and compatibility with PSR-7 interfaces.
- yiisoft/view-twig - an extension that provides a view renderer that will allow you to use the Twig view template engine, instead of the default PHP renderer.
The package is tested with PHPUnit. To run tests:
The code is statically analyzed with Psalm. To run static analysis:
The Yii View Rendering Library is free software. It is released under the terms of the BSD License.
LICENSE for more information.
Maintained by Yii Software.