Skip to content

Instantly share code, notes, and snippets.

@chinghanho
Created September 2, 2013 01:09
Show Gist options
  • Save chinghanho/6408406 to your computer and use it in GitHub Desktop.
Save chinghanho/6408406 to your computer and use it in GitHub Desktop.
<test data-test=" 'hello' "></test>
app.directive('test', function() {
return {
restrict: 'E',
link: function(scope, elem, attrs) {
console.log(scope.$eval(attrs.test)); # got `hello`
}
};
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment