As I explore how to implement authentication using Firebase in my Next.js app, one thing that stands out is the need to initialize Firebase with our configuration details (apiKey, etc.). The concern I have is when using any Firebase function from a client ...
After developing a Next.js application, I integrated Firebase authentication and utilized the useContext hook for managing user state throughout the app. Here's the snippet of code for the AuthContext: auth.js import { createContext, useState, useEff ...
I'm currently in the process of setting up and testing Google authentication for a web application that I'm developing. Unfortunately, I've encountered several issues with getting the JavaScript functions to work properly, and I am uncertain ...
My goal is to create a website where users can sign in with Google by clicking a button, and then be redirected to a new HTML page. However, I am facing an issue where the Google sign-in window pops up briefly and closes immediately, causing the HTML page ...
Encountering an issue with Vuex and Firebase Authentication integration. When reloading the page, there is a delay in response from firebase.auth().onAuthStateChanged. I require an immediate response upon page reload without using router guards as seen in ...
Hey there! I have a challenge in VueJS where I need to transfer Firebase Authentication user data (JSON) from the App.vue component to another component named Details.vue. The goal is to display the name of the logged-in user on Details.vue. In App.vue: ...
I'm facing difficulties when trying to create a next.js app with express and firebase-authentication. I'm also unsure about the role of redux in this setup. Can anyone please assist me with this or recommend some tutorials? I've found that the documentat ...
My Vue.js application structure within the src directory looks like this: . ├── App.vue ├── assets ├── data │ ├── config.js ├── main.js ├── router.js └── views └── app ├── index.vue ...
Currently, my email and password authentication flow in web Firebase JavaScript involves generating a token that I then verify on my node.js backend using firebase-admin. To make things easier, I store this generated token in the browser's local/session st ...
I encountered a problem with this code snippet from Firebase when trying to run it in Angular 2 CLI. It gives an error of 'unreachable code'. How can I fix this issue and get it to work properly? firebase.auth().currentUser.getToken(/forceRefres ...
Can a cookie store a token value? In my setup with js-cookie, Firebase auth/firestore, and Next.js, I am setting my cookie within the handleUser function like this: const handleUser = async (rawUser) => { if (rawUser) { const user = await fo ...
I am facing an issue with throwing an error when attempting to register an account with a previously used email using TypeScript, Firebase, and React. Despite successfully registering an account, the problem arises when I try to use the same email with a d ...
I need assistance with retrieving the username of the user during authentication using Firebase Github Auth. I am able to access all user information except for the username. Below is the code snippet: import React, { useState, useContext, createContext, u ...
Currently, I am utilizing Firebase to authenticate users with Google in my Angular project, "project1." When signing anonymously into Firebase, everything runs smoothly. However, if I attempt to sign in with Google using the popup feature, an error occurs: ...
I've been developing a project with the nextjs app router, and I'm facing an issue where the dashboardlayout inside the dashboard folder is accessible only to logged-in users, but the Rootlayout navbar and footer still appear even after login. Ho ...
I am in the process of developing a settings feature for user accounts on an application I've been working on. One key functionality I want to include is the ability for users to update their password directly from the account settings page. To enable this ...
Currently, when a user clicks 'logout', their session is terminated, and a database entry is removed. All other users can see that database entry, so the objective is for users to view each other's data only while they are logged in. For in ...
Within my AuthService, I have implemented a function for signing in with Google which, depending on the user's device, initiates the sign-in process either with a redirect or a pop-up. The pop-up sign-in functionality is operating smoothly, however, ...
I am new to React Native and facing challenges with managing authentication state in my application. Currently, I am using Redux but have not yet implemented persistence for user login. I have incorporated Firebase authentication. Essentially, I would li ...
Is there something odd happening here or am I overlooking a crucial detail? The template view I am working with is as follows: User-Profile.html <div id="divUserProfile" ng-controller="userProfileController"> <h1>User Profile</h1> ...
Currently, I am working on integrating Microsoft authentication with Firebase for a web project built in Vue.js 2. I have meticulously followed the steps outlined in the Firebase documentation and also referred to the Azure portal documentation for creatin ...
I've created a function called signup in my web project that uses JavaScript to add a user to my Firebase database. The function works fine, but I'm encountering an issue when I try to redirect to another page at the end of the function - the use ...
In my Angular application, I have created a service called AuthService: export class AuthService { public currentUser: Subject<firebase.User> = new Subject(); public currentUserId: Subject<string> = new Subject(); constructor(pri ...
I'm encountering an issue while trying to integrate authentication using firebase (via Google) in my next.js application, and the app crashes consistently. I will provide the code for the auth.js page component, as well as where I set up firebase and ...
My current project involves using React js in combination with Firebase authentication to verify users on a web application. I am utilizing the createUserWithEmailAndPassword and signInWithEmailAndPassword functions for user creation/sign-in, as well as th ...
When utilizing the following method: login() { this.afAuth.auth.signInWithPopup(new firebase.auth.GoogleAuthProvider()) .then(() => { this.router.navigate(['']); }); } An error occurs during logout: zone.js:915 Uncaught Error ...
I am working on two Vue projects integrated with Firebase. The first project was set up using webpack-simple, while the second one used just webpack. I have noticed that when I call signInWithEmailAndPassword in the simple project, it only returns: {"uid" ...
After conducting thorough research, I have learned that Firebase updates a refresh token every hour because Firebase ID tokens expire after one hour. It is mentioned that the automatic refreshing of tokens by Firebase occurs without any action required fro ...
Hey there fellow developers. I'm fairly new to react native and I'm trying to implement firebase authentication for a project. However, I'm stuck on how to include user name and country when using the standard auth().createUserWithEmailAndPassword method. ...
I implemented the use of Context API to manage user login state and also utilized Firebase Auth persistence to keep users logged in even after a page reload, however, it seems to not be working as expected. While the user information is being saved in the ...
After spending hours trying to fix my issue, I still can't figure it out. I've searched through related threads on SO, but haven't found a solution yet. Issue After successfully signing up, the email verification flag is set to true. However, when I try ...
Currently working on a website using Angular, I have integrated the Firebase SDK for email/password authentication. The main aim is to automatically generate a new token if the user closes the site and returns after a week. However, I am unsure which func ...
After upgrading to Angular2 Final, I completed the migration project steps to transition everything over. Surprisingly, there were no errors during authentication; however, the issue arises post-authentication. Upon redirection back to the page, the authen ...
I'm struggling with logging users out automatically from Firebase after they sign out of their Google account. My app relies on $signInWithPopup, so I need a way for Firebase to also log them out when they sign out of Google. I initially thought Angu ...
Just started using TypeScript and in the process of migrating my React app to incorporate it. Encountering some type issues with Firebase auth service that I can't seem to find a solution for. Any suggestions? import React, { useEffect, useState } from ' ...
I recently started a personal project using Next.js, Typescript, and Firebase for authentication and database management. While working on a sign-in page with Google integration, I encountered an error labeled as auth/argument-error. According to the Fireb ...
I have thoroughly gone through the Firebase Docs on "Managing Users" for web along with watching their instructional video on YouTube. Despite following the code they provide, I am encountering an error message that states: "Property 'afAuth' does not exi ...
Currently, I am working on an application where I am categorizing posts and users based on a specific room ID. I am adding a roomid property to both the user and every post. However, when attempting to fetch all posts belonging to a particular room ID, I e ...
The problem is related to an app created using Ionic/Cordova/Firebase technology stack. Users of the app on Android and IOS devices are experiencing random local storage wipes, resulting in the need for them to log in again. The authentication process is ...
I am currently working on a Vue.js and Firebase authentication interface with an email verification feature. The setup is such that the user cannot log in until they click the verification link sent to the email address provided during the login process. ...
Currently, I'm working on an application that utilizes firebase-auth for authentication. In my design, I've successfully secured the user component to only allow authenticated users. However, I now face the challenge of safeguarding the login com ...
In the process of developing a private route component that restricts unauthenticated users and redirects them to the homepage, we encountered an issue upon page refresh. The problem arises when the current user variable momentarily becomes null after a ...
I am currently working on a Next.js project with Firebase as the backend database. Within this project, there are multiple pages such as visitors.tsx, issues.tsx, and index.tsx (which serves as my login page). Upon logging in to the application, I am direc ...
Is it feasible to retrieve the user id from Firebase authentication API "email/password method" without logging in? Imagine a function that takes an email as a parameter and returns the firebase userId. getId(email){ //this is just an example return t ...
Utilizing Ionic2/Angular2 along with AngularFire2 and Firebase for user authentication during login. Upon successful registration of a user using email & password, I am able to log in with that same email & password without any issues. public fireAuth: ...
✅ I have successfully implemented the feature that allows users to update their profile with a mobile number using verifyPhoneNumber and update currentUser.updatePhoneNumber ❌ However, a problem arises when a new user attempts to sign in with a phone ...
Could anyone please help me with setting the OTP expire time in Next.js using Firebase? I have searched through the Firebase documentation but haven't been able to find a solution to my issue. Below is the code I am using to send the OTP: const appVerifi ...
As someone coming from an Angular background, I recently started using React and everything was going smoothly until I encountered an error while checking if Firebase is initialized: TypeError: _assets_Services__Firebase__WEBPACK_IMPORTED_MODULE_11__.defau ...
How can I efficiently sign out of an Angular application that uses Firebase Authentication and Firestore? Although I can successfully sign in with Google authentication, signing out poses some challenges. My ultimate goal is to ensure that when a user cli ...
Recently, I've been in the process of transitioning an existing project to Firebase 3/AngularFire 2 from a previous Firebase.com setup. This is my first time working with these technologies. My query revolves around using the $createUserWithEmailAndP ...
I need to verify the user's password again before allowing them to change it. Currently, my Firebase Auth setup is defined in Firebase.js and exported correctly //appConfig = ...(all the configurations here) const app = firebase.initializeApp(appConfig); ...
I've been utilizing Node.js with Express for my latest project and everything was running smoothly until I encountered an issue when trying to retrieve a collection using my middleware. Here is the snippet of my middleware: const FBAuth = (req, res, next ...
When using Google authentication with Firebase, is the Signup and Login logic the same? I am creating a page for user authentication but I'm unsure if I should have separate pages for signing up and logging in. This confusion arises from the fact that on ...
import { Injectable } from '@angular/core'; import { Router } from '@angular/router'; import { User } from './../classes/user'; import { AlertService } from './alert.service'; import { Alert } from './../classes ...
After developing a Next.js app with Firebase Google login functionality, everything was running smoothly in my local environment. However, upon deploying it to Railway and Vercel, the login feature seemed to malfunction. Whenever a user attempted to click ...
I have stored my unique username in the variable "$scope" and I am trying to access it from different views once the user logs in, using: However, when I refresh the page immediately after the user successfully signs in, the value of "$scope" goes bac ...
I have been trying to troubleshoot this issue by going through multiple posts, but the problem with uncaught promises when updating a user's profile persists. Below is the current function I am using. Any assistance would be greatly appreciated, thank ...
Currently, I am developing a cross-platform app for iOS and Android that utilizes a .vue view to handle authentication via Gmail on Firebase. My approach involves using Google as the provider: provider = firebase.auth.GoogleAuthProvider() firebase.auth().s ...
I have been trying to authenticate with Microsoft using a Capacitor plugin, but I haven't had any success so far. I carefully followed the instructions in this documentation and made sure everything is well configured. Could you please guide me on where ...
My situation is quite straightforward. I have developed a Firebase web application and I am logging in with my Google account. The problem arises when I have to keep logging back in every time the page is refreshed, as depicted in these steps: Initialize ...
I am currently working on the following code: import {Injectable} from '@angular/core'; import {ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot, UrlTree} from '@angular/router'; import {Observable} from 'rxjs' ...
I am currently in the process of integrating Firebase authentication with the standard UI into my node.js application. On the login page, I have included the code snippet below: // Initialize Firebase var config = { apiKey: "...", authDomain: "... ...
I recently upgraded my AngularJS app to use Firebase 3.x and AngularFire 2.x for email and password authentication. I referred to the following documentation for migration: https://firebase.google.com/support/guides/firebase-web https://github.com/fi ...
Recently, I came across an old tutorial on Redux-Firebase-Angular Authentication. In the tutorial, there is a confusing function that caught my attention: The code snippet in question involves importing Actions from @ngrx/effects and other dependencies to ...
Struggling to show error messages during the sign-up process? Constantly encountering the same issue in your code? The error TS1308 is throwing you off: 'await' expression is only allowed within an async function. Take a look at this problemati ...
I am currently working on integrating firebase auth into my app. The login controller is functioning properly, but I am facing an issue where the user gets logged out immediately after logging in. .controller('LoginCtrl', function ($scope, $location, user ...
Currently, I am encountering an issue with the auth.onAuthStateChanged function in my Firebase user authentication service integrated with ReactJS. The function fires after the component has already been rendered, causing problems with redirecting users to ...
I have set up routes, the AuthGuard, and Firebase login in my project. I am using callbacks to handle the success and failure of the Firebase login process. successCallback(signInSuccessData) { console.log("Received with Success!"); } errorCallback(e ...
During the transition from Firebase to Auth0, my Angular front-end application authenticates users to either Firebase or Auth0 based on their email address. I am working on configuring the Auth0 AuthHttpInterceptor provided in the Auth0 Angular SDK for SPA ...
I've encountered an issue with my NodeJS server where I need to validate a Firebase token before proceeding with the validation of the phone number and saving a file. The code structure involving busboy and express is as follows: function authent ...
I am currently experimenting with an Ionic application that utilizes a Firebase backend. The issue I'm facing is that the ng-click="loginUser(user)" function does not seem to be triggering. When checking the console, it only displays Signed Out from Auth. ...
Currently, I am in the process of enhancing an existing Firebase Auth project by transitioning to Identity Platform to take advantage of multi-tenancy features. During my testing phase on the local emulator, I encountered some challenges: Users are not a ...
When attempting to import the 'auth' module from my 'firebase.js' file, I encountered an error. I used the code import {auth} from "./firebase", which resulted in the following error message: Error: Unable to locate module './firebase' in path ' ...
I am working on creating a user authentication page in react using firebase. I am able to sign in successfully, but the sign in button does not change to sign out after signing in. Can anyone help me diagnose the issue? const handleAuthentication ...
I need to remove Email from a user who already has both a Phone Number and Email linked. This is what I tried: admin.auth().updateUser("user uid", { email: null, password: null, }) .then(function(userRecord) { // Check the UserRecord re ...