I'm new in angular js and bumped ( I think ) in to simple problem. Sorry if I dublicated question, but I can't find any related topics.
I need to set $scope variable without affecting each other, but then I'm setting them, both are updated with the same results:
var defaultFilterValues = {
show_limit: 20,
purpose: {}
};
$scope.filter = defaultFilterValues;
console.log($scope.filter);
console.log(defaultFilterValues);
If I set $scope.filter = { /* any data */ } both results are updated, how I can isolate defaultFilterValue to always have primary results?