I have come across an issue related to generating new $$hashKey within the following code snippet:
this.list = '[{
"body": "asdf",
"tag": "resolved",
"time": "2147483647",
"id": "51"
}, {
"body": "asdf",
"tag": "undone",
"time": "2147483647",
"id": "138"
}, {
"body": "asdf",
"tag": "undone",
"time": "2147483647",
"id": "139"
}]';
this.addTask = function(body) {
newObj.body = body;
newObj.tag = 'undone';
newObj.time = Date.now();
this.list.push(newObj);
}
Upon adding a second object, its $$hashKey remains the same which causes an error during ng-repeat
of this.list
.
I am looking for guidance on how to manually increment the $$hashKey or if there is a simpler solution available.