I meet a js problem "TypeError: this.menu is undefined" when using AutoComplete
use yii\web\JsExpression;
$data = ['usa', 'rus'];
echo yii\jui\AutoComplete::widget ( [
'name' => 'Company',
'id' => 'ddd',
'clientOptions' => [
'source' => $data,
'autoFill' => true,
'minLength' => '4'
]
] );
public $depends = [
'yii\web\YiiAsset',
'yii\bootstrap\BootstrapAsset',
'yii\web\JqueryAsset',
'yii\jui\AutoCompleteAsset',
'yii\jui\MenuAsset'
];