Fire-base user registration


so im trying to make a registeration for a user on firebase and i want the users data such as name,email,password, age…etc all to be saved once he registers

anyone know how i can do so, im currently using this.afAuth.auth.createUserWithEmailAndPassword(newEmail, newPassword)
but it just creates a user with email and pass in the database


you could do

this.afAuth.auth.createUserWithEmailAndPassword(newEmail, newPassword)
.then(() => { let createThisUser = firebase.database().ref('Users').push(); 
                 ({ name: newUserName, 
                    age: newUserAge,
                    email: newEmail, 
                    reminder: newPassword,
                    key: createThisUser.key })

I personally like adding the key property to firebase items to set the key in other categories, or add the key to other categories as a reference.