Search Results

Search found 1 results on 1 pages for 'c1pher'.

Page 1/1 | 1 

  • Using attribute text value in AngularJS directive

    - by C1pher
    Using a YouTube tutorial created by John Lindquist, I was able to create a directive using a template. See fiddle: http://jsfiddle.net/37PSs/ Now, I want to use the value of the attribute as a variable to a function call. Something like this: html: <hello-world name="World"></hello-world> javascript - directive: template: '<span>myFunction({{name}})</span>' javascript - myFunction(theirName): return ("Hello, " + String(theirName) + "!"); The closest I've been able to get is passing an [object Window] to my function.

    Read the article

1