I have an angular directive:
angular.module("App").directive("myButtons", function () {
return {
restrict: "E",
scope:
{
teststring: '@'
},
templateUrl: "test.html"
}
});
with the following template:
<div>
<input type="button" onclick="teststring" value="Hi" />
</div>
This is the directive in the HTML:
<my-buttons teststring="Whatsup" />
I want the value that I pass into teststring to appear in the rendered html.
At the moment I just get onclick="teststring".
What am I doing wrong. I've tried added {{ }} on the template and also @, = and & on the scope value.