November 2017
Beginner to intermediate
288 pages
7h 33m
English
Within our example, we'll have an express server running which will give us the possibility to have some basic routes that we'll use in order to create our dashboard, and what needed now is to have a route that will help us create a user, so let's see how to implement that.
req.post('/create/users', (req, res) => { let {email, password, fullName, image} = req.body; admin.auth().createUser({ email : email, password: password, //Must be at least six characters long displayName: fullName, photoURL: image }) .then(user => { //[*] Do something within the response ! }) .catch(err => { logger.error(`External Error: While creating new account, with error : ${err}`); res.json({ message: `Error: while creating new account, with ...Read now
Unlock full access