Returns the value for property_chain
on the current scope. Unlike in JavaScript, if there
are any undefined
intermediary properties, undefined
is returned instead of throwing an
exception.
var scope = angular.scope(); expect(scope.$get('person.name')).toEqual(undefined); scope.person = {}; expect(scope.$get('person.name')).toEqual(undefined); scope.person.name = 'misko'; expect(scope.$get('person.name')).toEqual('misko');
angular.scope.$get(property_chain);
property_chain – {string} –
String representing name of a scope property. Optionally
properties can be chained with .
(dot), e.g. 'person.name.first'
{*}
– Value for the (nested) property.