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

InOb: Force polyfill for WebKit document=root #32182

Merged
merged 5 commits into from
Jan 26, 2021
Merged

Conversation

samouri
Copy link
Member

@samouri samouri commented Jan 25, 2021

summary
Due to a InOb WebKit bug (https://bugs.webkit.org/show_bug.cgi?id=219495), we should force the InOb polyfill for all WebKit-based browsers. The polyfill already will choose a Native InOb when available + non-document root is requested on a per-instance basis, which works well for this case.

Note: I've never written UA engine detection code before, so I'm still researching now to ensure WebKit is safe as a regex test.

src/polyfillstub/intersection-observer-stub.js Outdated Show resolved Hide resolved
test/unit/polyfills/test-intersection-observer.js Outdated Show resolved Hide resolved
@amp-bundle-size amp-bundle-size bot requested a review from rsimha January 25, 2021 20:54
@rsimha rsimha removed their request for review January 25, 2021 21:24
@samouri samouri merged commit c357ab9 into ampproject:master Jan 26, 2021
PetrBlaha pushed a commit to PetrBlaha/amphtml that referenced this pull request Jan 28, 2021
* InOb: Force polyfill for WebKit documnent=root

* lint

* Use Platform Service. TODO: stub.

* Stop using Platform service, use navigator.vendor

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

Successfully merging this pull request may close these issues.

None yet

3 participants