angularfire - Update part of record firebase -


i have firebase node called comment{textcmnt, datecmnt} try code update textcmnt node updated.

var obj = $firebaseobject(ref.child('/comment/'+$scope.c.$id)); obj.textcmnt="new text";  obj.$save(); 

any please.

there no method built angularfire that. luckily angularfire built on top of firebase javascript sdk, has method purpose:

ref.update({ textcmnt: "new text" }); 

and since angularfire built on top of that, interoperate perfectly.


Comments

Popular posts from this blog

ios - Memory not freeing up after popping viewcontroller using ARC -

Django REST Framework perform_create: You cannot call `.save()` after accessing `serializer.data` -

Why does Go error when trying to marshal this JSON? -