无标题文档
{{item}} + {{m}}
<script><br />
var app = angular.module("app", []);<br />
function c($scope){<br />
$scope.items = [1,2,2,3,4,5,5];<br />
$scope.m = "string";<br />
};<br />
app.directive("dir",function($parse){<br />
return {<br />
compile : function( $compile ){<br />
return function(s,e,a){<br />
//what .. ..<br />
//a.ngModel<br />
//用$("xxx").scope.xx = model<br />
//assign 分配<br />
//console.log( $parse( a.ngModel ).assign(s,"sdfs__________newValue__________dfd") )<br />
s.m = "<a href="mailto:sdfs____#@$#@$#@$@#$__dfd">sdfs____#@$#@$#@$@#$__dfd这两个效果一摸一样";<br />
}<br />
}<br />
}<br />
});<br />
</script>