RESOLVED FIXED 270057
Remove non-standard `webkitBackingStorePixelRatio`
https://bugs.webkit.org/show_bug.cgi?id=270057
Summary Remove non-standard `webkitBackingStorePixelRatio`
Ahmad Saleem
Reported 2024-02-25 15:42:34 PST
Hi Team, I am raising this bug since I couldn't find same. In Safari, currently we return `1` for 'webkitBackingStorePixelRatio' while in Firefox and Chrome - it is undefined. I think we should remove this and align with other browsers. Blink removed it in 2014 with following PR - https://src.chromium.org/viewvc/blink?view=revision&revision=170324 Appreciate if someone can share any input. Happy to do PR to do clean-up. Also we have also few more legacy APIs, which I am happy to remove. Less code to maintain and also less fingerprinting as well on web. Thanks!
Attachments
Radar WebKit Bug Importer
Comment 1 2024-03-03 15:43:13 PST
Karl Dubost
Comment 2 2024-03-04 01:07:54 PST
Ahmad Saleem
Comment 3 2024-07-19 02:40:58 PDT
Brent Fulgham
Comment 4 2024-07-19 14:06:00 PDT
Note that all major browsers seem to have an analog of this: ``` context.webkitBackingStorePixelRatio || context.mozBackingStorePixelRatio || context.msBackingStorePixelRatio || ``` We will want to make sure this doesn't break sites that try to use this for something.
Ahmad Saleem
Comment 5 2024-07-19 14:18:18 PDT
(In reply to Brent Fulgham from comment #4) > Note that all major browsers seem to have an analog of this: > > ``` > context.webkitBackingStorePixelRatio || > context.mozBackingStorePixelRatio || > context.msBackingStorePixelRatio || > ``` > > We will want to make sure this doesn't break sites that try to use this for > something. I have updated it to check for `moz` - https://jsfiddle.net/z069fcp2/3/ It is `undefined` in Mozilla Firefox. Additionally - people are using following workaround - https://gist.github.com/callumlocke/cc258a193839691f60dd leveraging `devicePixelRatio` to workaround the functionality provided by this API.
EWS
Comment 6 2024-12-08 15:03:24 PST
Committed 287523@main (bc5250e9ad63): <https://commits.webkit.org/287523@main> Reviewed commits have been landed. Closing PR #25080 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.