app.directive('myCustomAttr',function() {
return {
restrict: 'A',
scope: {
valueOfAttr : "@myCustomAttr"
},
};
});
How would I pass the value of the attribute? Thus far, I've only found examples that use restrict : 'E'.
<input type="text" my-custom-attr="myValue" />
So, if I were going to bind "myValue" to the scope, how would I do that?
[EDIT]
Sorry, I had a typo. I was using the my-custom-attribute correctly, but it still doesn't seem to bind in the directive.