Comments (9)
@jinguohao1991 @IcebergRage I know the reason. Due to the cookies library is not working and I'm trying to find a way to help you.
read more:
joeferraro/react-native-cookies#78
joeferraro/react-native-cookies#127
currently, temporary solution is disable cookies, but in some cases when logging back, we need to keep cookies, and users don't need to log in again.
So i still recommend persist cookies and clear cookies when logout.
We can try with another library manage cookies.
@jinguohao1991 here is code for you:
<InstagramLogin
ref={ref => this.instagramRef = ref}
clientId='************'
redirectUrl='************'
scopes={['basic']}
onLoginSuccess={(token) => this.setState({ token })}
onLoginFailure={(data) => this.setState({ failure: data })}
cacheEnabled={false}
incognito={true}
thirdPartyCookiesEnabled={false}
sharedCookiesEnabled={false}
domStorageEnabled={false}
/>
from react-native-instagram-login.
I found :
Add this in Webview
cacheEnabled={false}
incognito={true}
thirdPartyCookiesEnabled={false}
sharedCookiesEnabled={false}
domStorageEnabled={false}
I will do a PR soon
from react-native-instagram-login.
@jinguohao1991 To login with another account, you must clear cookies before login another account.
Please read:
https://github.com/hungdev/react-native-instagram-login#logout
from react-native-instagram-login.
@jinguohao1991 Feel free to let me know if you cant resolve your problem.
from react-native-instagram-login.
Thank you for your reply.
I have still the same issue.
I have installed "react-native-cookies": "^3.3.0", and linked to iOS manually.
This is my code for opening Instagram Login modal
const onInstaLoginClick = () => {
CookieManager.clearAll().then(() => {
this.setState({ token: null })
});
this.instagramLogin.show();
};
The instagram still logs in with previous Account automatically.
So I cannot use another account.
from react-native-instagram-login.
I have tried your example with your video.
Here is my recorded video.
https://www.youtube.com/watch?v=6W-RVOUFLqE&feature=youtu.be
Thank you.
from react-native-instagram-login.
Hello, I have the same issue.
Do you have any solution ?
from react-native-instagram-login.
Hi, @IcebergRage. Thank you.
If I test with https://github.com/hungdev/react-native-instagram-login/tree/master/Example, where to put this code?
Inside this package directly or inside my code?
Hope your update.
from react-native-instagram-login.
@jinguohao1991 @IcebergRage I know the reason. Due to the cookies library is not working and I'm trying to find a way to help you.
read more:
joeferraro/react-native-cookies#78
joeferraro/react-native-cookies#127
currently, temporary solution is disable cookies, but in some cases when logging back, we need to keep cookies, and users don't need to log in again.
So i still recommend persist cookies and clear cookies when logout.
We can try with another library manage cookies.
@jinguohao1991 here is code for you:<InstagramLogin ref={ref => this.instagramRef = ref} clientId='************' redirectUrl='************' scopes={['basic']} onLoginSuccess={(token) => this.setState({ token })} onLoginFailure={(data) => this.setState({ failure: data })} cacheEnabled={false} incognito={true} thirdPartyCookiesEnabled={false} sharedCookiesEnabled={false} domStorageEnabled={false} />
This works perfectly for me.
<InstagramLogin
ref={ref => this.instagramRef = ref}
clientId=''
redirectUrl=''
scopes={['basic']}
onLoginSuccess={(token) => this.setState({ token })}
onLoginFailure={(data) => this.setState({ failure: data })}
cacheEnabled={false}
useWebKit={true}
sharedCookiesEnabled={true}
/>
from react-native-instagram-login.
Related Issues (20)
- 403 Error [URGENT] HOT 15
- Invalid Response Type token HOT 2
- Getting Invalid User Id
- "Continue with Facebook" doesn't work. HOT 4
- Could you update axios so it is no longer a critical vulnerability HOT 5
- Adding types HOT 2
- How is this component secure? The app secret is required in the component? HOT 1
- Redirect on a mobile screen
- returns status 403 when using code to fetch access token HOT 16
- signup with instagram working on amulator debug mode but not working when I close debuger HOT 2
- Getting Invalid User Id
- Documentation has incorrect params HOT 2
- onLoginFailure being triggered every time HOT 49
- after logging in it redirect the user to the redirect url in android that is set to google (ios is working fine) HOT 2
- WebView error: Invalid plateform app HOT 3
- react-native-instagram-login page return a HTML page on failure HOT 2
- Invalid scope [ ] error HOT 4
- react-native-instagram-login throwing Invariant Violation HOT 3
- Opens instagram app HOT 1
- Deprecating Facebook Login support on Android WebViews HOT 4
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-native-instagram-login.