I'm currently using push as it gives me a randomly ( or quazi-random ) unique identifier.
I'm in a scenario where I would prefer to use updates instead of pushes.
Is there anyway I can ask firebase to genarate a unique if for me? Or would be be best to genarate on client side and if so how would I guard against updating a already existing key?
var updates = {};
updates['model/' + <i_need_new_unique_key_here>] = someVariable;
firebase.database().ref().update(updates);