Skip to content

Genesis671230/social-Card

Repository files navigation

auth.sendPasswordResetEmail(email)

import { getAuth, sendPasswordResetEmail } from "firebase/auth";

const auth = getAuth(); sendPasswordResetEmail(auth, email) .then(() => { // Password reset email sent! // .. }) .catch((error) => { const errorCode = error.code; const errorMessage = error.message; // .. });

import { getAuth, deleteUser } from "firebase/auth";

const auth = getAuth(); const user = auth.currentUser;

deleteUser(user).then(() => { // User deleted. }).catch((error) => { // An error ocurred // ... });

import { getAuth, updateProfile } from "firebase/auth"; const auth = getAuth(); updateProfile(auth.currentUser, { displayName: "Jane Q. User", photoURL: "https://example.com/jane-q-user/profile.jpg" }).then(() => { // Profile updated! // ... }).catch((error) => { // An error occurred // ... });

import { doc, setDoc, updateDoc } from "firebase/firestore";

// Create an initial document to update. const frankDocRef = doc(db, "users", "frank"); await setDoc(frankDocRef, { name: "Frank", favorites: { food: "Pizza", color: "Blue", subject: "recess" }, age: 12 });

// To update age and favorite color: await updateDoc(frankDocRef, { "age": 13, "favorites.color": "Red" });

// Create our initial doc db.collection("users").doc("frank").set({ name: "Frank", favorites: { food: "Pizza", color: "Blue", subject: "Recess" }, age: 12 }).then(function() { console.log("Frank created"); });

About

A social accounts manager

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages