状況:
その要素をテンプレートにラップする属性ディレクティブがあります。ここにあります:
app.directive("myCustomInput", function(){
return{
restrict: "A",
replace: true,
scope:{},
transclude: "element",
template: "<div class='input-wrap'>"+
"<div ng-transclude></div>"+
"<i class='glyphicon glyphicon-chevron-down'></i>"+
"</div>"
}
});
そして、私はそれを次のように使用します:
<input my-custom-input ng-model="data.input" type="text" />
問題:
ng-model
動作しません
ここにプランカーがあります