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

fix: Same-origin iframe set/get cookie/localStorage bug #600

Merged
merged 2 commits into from
Jun 12, 2024

Conversation

SarahJane87
Copy link
Contributor

What is it?

  • Feature / enhancement
  • Bug
  • Docs / tests

Description

Bug: Unable to get/set localStorage/cookies in a same-origin iframe created with Partytown.

Expected: Able to get/set localStorage/cookies in a same-origin iframe created with Partytown.

Fix: Set isSameOrigin after iframe src is set

Use cases and why

"Partytown unable to get cross-origin localStorage" warning from Pinterest tracking pixel even though iframe src https://ct.pinterest.com/ct.html is proxied.

Checklist:

  • My code follows the developer guidelines of this project
  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • Added new tests to cover the fix / functionality

Copy link

vercel bot commented Jun 10, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
partytown ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 10, 2024 11:07pm

@SarahJane87 SarahJane87 changed the title Same-origin iframe set/get cookie/localStorage bug fix: Same-origin iframe set/get cookie/localStorage bug Jun 10, 2024
Copy link
Member

@gioboa gioboa left a comment

Choose a reason for hiding this comment

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

Thanks for your help @SarahJane87
It looks great to me

@gioboa gioboa merged commit b292a14 into QwikDev:main Jun 12, 2024
9 of 10 checks passed
@SarahJane87 SarahJane87 deleted the iframe-same-origin branch July 23, 2024 16:08
@github-actions github-actions bot mentioned this pull request Dec 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants