wrong documentation installation
antgubarev opened this issue · 5 comments
antgubarev commented
[
'components' => [
'view' => [
'class' => 'yii\web\View',
'renderers' => [
'twig' => [
'class' => 'yii\twig\ViewRenderer',
'cachePath' => '@runtime/Twig/cache',
// Array of twig options:
'options' => [
'auto_reload' => true,
],
'globals' => [
'html' => ['class' => '\yii\helpers\Html'],
],
'uses' => ['yii\bootstrap'],
],
// ...
],
],
],
]
'html' => ['class' => '\yii\helpers\Html']
dont work, but
'html' => '\yii\helpers\Html'
work
Additional info
Q | A |
---|---|
Yii vesion | 2.0.11 |
PHP version | 7.1 |
antgubarev commented
I forgot to say that
{{ html.csrfMetaTags | raw }}
or other methods throw exception
egorsmkv commented
Confirm.
samdark commented
Anyone want to work on a fix?
egorsmkv commented
Minute. I will make a PR.
antgubarev commented
Thank you!