Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add option to set cookies before visiting loginUrl #122

Merged
merged 1 commit into from
Apr 8, 2022

Conversation

Pascalmh
Copy link
Contributor

@Pascalmh Pascalmh commented Apr 8, 2022

Description

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Related Issue

Motivation and Context

We needed to set a cookie so our feature(toggle) was enabled and the social login could be done as expected

How Has This Been Tested?

I tested it locally with my actual cypress project

Checklist:

  • I have updated the documentation (if required).
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I added a picture of a cute animal cause it's fun

image

@lirantal lirantal self-requested a review April 8, 2022 10:30
@lirantal lirantal assigned mirzamusic and Pascalmh and unassigned mirzamusic Apr 8, 2022
Copy link
Owner

@lirantal lirantal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

@lirantal
Copy link
Owner

lirantal commented Apr 8, 2022

This is awesome. Thank you Pascal 🙌

@lirantal lirantal merged commit ee43739 into lirantal:master Apr 8, 2022
@lirantal
Copy link
Owner

lirantal commented Apr 8, 2022

🎉 This PR is included in version 1.14.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@Pascalmh Pascalmh deleted the preVisitLoginUrlSetCookies branch April 8, 2022 12:04
@Pascalmh
Copy link
Contributor Author

@lirantal that was fast! Thank you - I just upgraded to v1.14.0 in our cypress project, added the preVisitLoginUrlSetCookies-option and our test works 🟢

Thanks for this Plugin, helps us ship our work with confidence!

@lirantal
Copy link
Owner

That's awesome @Pascalmh, thanks for sharing, and I'm happy here to help support it :)

Curious - are you actually running it on CI or just on local dev machines? there has been some issues with social connecting providers due to the captcha and rigorous mitigations if you just try to sign-in from a new IP.

@Pascalmh
Copy link
Contributor Author

Yes, we run it on CI - but only once a day, we use the AmazonSocialLogin with 2FA enabled.

@lirantal
Copy link
Owner

Thanks. How do you pass through the 2FA part? or is that why you have the pre-visit cookie pull request? :)

@Pascalmh
Copy link
Contributor Author

We use the otpSecret-option to fill in the 2FA Code. The pre-visit cookie is used to enable a feature (feature toggled).

@lirantal
Copy link
Owner

Ahh got it. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants