When my app loads, it sends a request to the back-end to load a coarse grained JSON payload and I store it in $scope.data
.
Then I want to fetch a property from $scope.data
and store it in $scope.netWorkDetails
(code is just an example):
$scope.networkDetails = {
type: $scope.data.network.type;
}
Is there a way to bind $scope.networkDetails
to $scope.data.network.type
, so that it gets updated whenever $scope.networkDetails
changes?