From c9635dd9b10d81840111869339282fe0db1d9e30 Mon Sep 17 00:00:00 2001 From: Alexander Makarov <sam@rmcreative.ru> Date: Mon, 5 May 2014 01:55:45 +0400 Subject: [PATCH] Added class example to Twig extension docs --- docs/guide/tutorial-template-engines.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/guide/tutorial-template-engines.md b/docs/guide/tutorial-template-engines.md index 6349b78..56a4168 100644 --- a/docs/guide/tutorial-template-engines.md +++ b/docs/guide/tutorial-template-engines.md @@ -132,6 +132,7 @@ helpers and your own variables there: 'globals' => [ 'html' => '\yii\helpers\Html', 'name' => 'Carsten', + 'GridView' => '\yii\grid\GridView', ], ``` @@ -139,6 +140,8 @@ Once configured, in your template you can use the globals in the following way: ``` Hello, {{name}}! {{ html.a('Please login', 'site/login') | raw }}. + +{{ GridView.widget({'dataProvider' : provider}) | raw }} ``` #### Functions -- libgit2 0.27.1