I am using Firebase with Angular 2 to create new users. I would like to extend this by adding additional data for each newly created user. In this example, I would like to have every newly created user start with an assigned property of net worth = 5000. So my schema would look something like:
email | ''
password | ''
net worth | '5000'
Having gone through the Firebase docs, I have found the save data feature. However, I am unsure how to merge the set feature with my username and password authentication script.
Below is the basic signup script.
signup(){
firebase.auth().createUserWithEmailAndPassword('[email protected]', 'ucantcme')
.catch(function(error){
console.log(error);
});}
I would like to know how to implement the set feature with this signup so I can add default data for users.