Comments (5)
Just to clarify, in case anyone comes into contact with this issue. The AUTH API within the firebase.js file uses fat arrow functions without curly braces. If curly braces are introduced, a return statement is required in order for the promise to be returned for the .then function in the SignUp component.
.then is undefined in the following:
doCreateUserWithEmailAndPassword = (email, password) => { this.auth.createUserWithEmailAndPassword(email, password); }
the following options return a valid response:
(return statement added)
doCreateUserWithEmailAndPassword = (email, password) => { return this.auth.createUserWithEmailAndPassword(email, password); }
or (no curly braces)
doCreateUserWithEmailAndPassword = (email, password) => this.auth.createUserWithEmailAndPassword(email, password);
Correct me if I'm wrong! (Amazing work, by the way)
from react-firebase-authentication.
It looks like my addition of {}
broke it by not returning the promise. Then I get Can't call setState (or forceUpdate) on an unmounted component.
in the console, which went away when I removed // this.setState(() => ({ ...INITIAL_STATE }));
. Thanks for the quick response, sorry about opening a bug for something that was user error.
from react-firebase-authentication.
Hm, I never experienced this nor did anybody else. Why do you think that it doesn't work?
from react-firebase-authentication.
Hey, thanks for getting back to me. I just realized I changed something in the doCreateUser
in db.js
.
When I change it to this:
export const doCreateUser = (id, fullname, username, email) => {
db.ref(`users/${username}`).set({
fullname,
email,
});
}
it doesn't work anymore. Do you know why this might be?
from react-firebase-authentication.
No worries. Glad that you've figured out the issue :)
from react-firebase-authentication.
Related Issues (20)
- Security issues: Missing Firebase db security rules HOT 1
- Unhandled Rejection (TypeError): Cannot read property 'roles' of null HOT 32
- Component labelled SignUpForm instead of SignUpFormBase HOT 1
- error of: A continue URL must be provided in the request. HOT 2
- Security rules format HOT 2
- These dependencies were not found HOT 1
- Commercial License links not working HOT 3
- Email Verification Issue HOT 1
- Firebase Auth Error HOT 2
- Failed at the [email protected] install script HOT 2
- "roles" type mismatch in google signin component
- Add multiple observers to this.listener to React component class
- Can you implement it using hooks api?
- Functions are not valid as a React child
- How can i hide config values? HOT 2
- Localstorage is not updated after SignUp
- How to access authUser.uid from firebase.js HOT 2
- A quick question and a thank you! HOT 1
- Admin Dashboard: <UserItem> does not show up. Switch issues ? HOT 1
- Webpage not working HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-firebase-authentication.