Comments (7)
Howdy,
same issue here rising for awareness.
Many thanks
Jamie
from firebaseui-web-react.
Hi,
Looks like firebaseui.auth.CredentialHelper.GOOGLE_YOLO is actually a string.
So in your firebeasui-web-react config instead of credentialHelper: firebaseui.auth.CredentialHelper.GOOGLE_YOLO
put
credentialHelper: 'googleyolo'
Seems to be working for me so far. I.E does the google one tap login in Chrome.
Your usage may vary.
from firebaseui-web-react.
Try importing firebaseui:
import * as firebaseui from 'firebaseui'
from firebaseui-web-react.
Try importing firebaseui:
import * as firebaseui from 'firebaseui'
This does not work as it generates window not defined error on next js.
from firebaseui-web-react.
Hi,
Looks like firebaseui.auth.CredentialHelper.GOOGLE_YOLO is actually a string.
So in your firebeasui-web-react config instead of credentialHelper: firebaseui.auth.CredentialHelper.GOOGLE_YOLO put credentialHelper: 'googleyolo'
Seems to be working for me so far. I.E does the google one tap login in Chrome. Your usage may vary.
Could you please share a code block or demo.. as it still doesn't work even after manually adding 'googleyolo' to credentialHelper.
from firebaseui-web-react.
Try importing firebaseui:
import * as firebaseui from 'firebaseui'This does not work as it generates window not defined error on next js.
You cannot SSR FirebaseUI. See firebase/firebaseui-web#213
You could do something like this:
const FirebaseAuth = () => {
const [renderAuth, setRenderAuth] = useState(false)
useEffect(() => {
if (typeof window !== 'undefined') {
setRenderAuth(true)
}
}, [])
return (
<div>
{renderAuth ? (
<StyledFirebaseAuth uiConfig={uiConfig} firebaseAuth={firebaseApp.auth()} />
) : null}
</div>
)
}
Also, you need to import FirebaseUI as:
import * as firebaseui from 'firebaseui'
from firebaseui-web-react.
Hi,
Looks like firebaseui.auth.CredentialHelper.GOOGLE_YOLO is actually a string.
So in your firebeasui-web-react config instead of credentialHelper: firebaseui.auth.CredentialHelper.GOOGLE_YOLO put credentialHelper: 'googleyolo'
Seems to be working for me so far. I.E does the google one tap login in Chrome. Your usage may vary.Could you please share a code block or demo.. as it still doesn't work even after manually adding 'googleyolo' to credentialHelper.
Hi @trueman1
it would be something like this:
`import firebase from 'firebase/app';
import 'firebase/auth';
const firebaseAuthConfig = {
signInFlow: 'popup',
signInOptions: [
{
provider: firebase.auth.EmailAuthProvider.PROVIDER_ID,
requireDisplayName: false,
},
{
provider: firebase.auth.GoogleAuthProvider.PROVIDER_ID,
clientId: ENV_VAR_FOR_YOUR_GOOGLEAUTHPROVIDER_CLIENT_ID
,
},
{
provider: firebase.auth.GithubAuthProvider.PROVIDER_ID,
},
],
signInSuccessUrl: '/dashboard',
credentialHelper: 'googleyolo',
callbacks: {
signInSuccessWithAuthResult: () =>
false,
},
};`
But there is more to it than the above.
the ENV_VAR_FOR_YOUR_GOOGLEAUTHPROVIDER_CLIENT_ID would be your GOOGLEAUTHPROVIDER_CLIENT_ID
You'd get this by using Google Cloud Platform.
You'll need to setup on Google Cloud Platform a Google API client ID
https://developers.google.com/identity/gsi/web/guides/get-google-api-clientid
from firebaseui-web-react.
Related Issues (20)
- Unhandled Runtime Error - TypeError: Cannot read property 'initializeApp' of undefined HOT 3
- /example/README.md doesn't mention creating an app first HOT 2
- Firebase-config.json is not created! HOT 1
- Support React 18 HOT 6
- Error when using PhoneAuthProvider - Uncaught TypeError: app.auth is not a function HOT 8
- React 18 StrictMode causes "AuthUI instance is deleted" error HOT 4
- StyledFirebaseAuth does not render with firebase ^9.8.1 HOT 3
- Question: how to get a refresh token
- Cannot Install in React 18.2 HOT 5
- Styledfirebaseui don't know my initializaion HOT 2
- StyledFirebaseAuth not working with nextjs HOT 8
- `StyledFirebaseAuth` cannot be used as a JSX component HOT 1
- AnonymousAuthProvider signInOptions does not work; Throw a TypeError.
- React strict mode compatibility HOT 1
- [email protected] is not compatible with [email protected] HOT 11
- Is this project maintained? HOT 7
- Is there a builtin rate-limiter or CAPTCHA in this?
- How do I add a custom domain redirect to this auth? HOT 1
- Link with Multiple Accounts is not working
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 firebaseui-web-react.