我正在尝试在Angular指令中包装kendoAutocomplete。问题是我收到以下错误消息:TypeError:'undefined'不是函数(评估'e(data)')
任何想法可能是问题的原因?
<input id="selectDomain" select-kendo=""/>
-----
var kendo = angular.module('kendo',[]);
kendo.directive('selectKendo', function () {
var data = [
"Sweden",
"Switzerland",
"Turkey",
"Ukraine",
"United Kingdom",
"Vatican City"
];
return {
restrict: 'A',
scope: {
},
link: function (scope, element) {
console.log(element);
$(element).kendoAutoComplete({
dataSource: data,
filter: "startswith",
placeholder: "Domain",
separator: ", "
});
}
}
});