diff options
Diffstat (limited to 'src/ng/compile.js')
| -rw-r--r-- | src/ng/compile.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ng/compile.js b/src/ng/compile.js index 18adc2c9..32c1d1ca 100644 --- a/src/ng/compile.js +++ b/src/ng/compile.js @@ -735,9 +735,13 @@ function $CompileProvider($provide) { scope[scopeName] = value; }); attrs.$$observers[attrName].$$scope = parentScope; + if( attrs[attrName] ) { + // If the attribute has been provided then we trigger an interpolation to ensure the value is there for use in the link fn + scope[scopeName] = $interpolate(attrs[attrName])(parentScope); + } break; } - + case '=': { parentGet = $parse(attrs[attrName]); parentSet = parentGet.assign || function() { |
