Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: afcd0d3bf64b4e8942e9b01db34400a161a2619e
      
https://github.com/WebKit/WebKit/commit/afcd0d3bf64b4e8942e9b01db34400a161a2619e
  Author: Timothy Hatcher <timo...@apple.com>
  Date:   2024-03-11 (Mon, 11 Mar 2024)

  Changed paths:
    M Source/WebKit/UIProcess/Extensions/Cocoa/WebExtensionCocoa.mm
    M Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebExtension.mm

  Log Message:
  -----------
  Prefer `scripts` and `page` over `service_worker` in Web Extension manifest.
https://webkit.org/b/270750
rdar://problem/124334426

Reviewed by Brian Weinstein.

This has been discussed in https://github.com/w3c/webextensions/issues/282.
When an extension specifies multiple `background` keys, the browser can prefer
which one to use based on what is supported. We support all three, but service
worker support is not the best environment for WebKit Web Extensions.

In the scenario where all three are supplied, we prefer `scripts`, `page`,
then `service_worker`.

* Source/WebKit/UIProcess/Extensions/Cocoa/WebExtensionCocoa.mm:
(WebKit::WebExtension::populateBackgroundPropertiesIfNeeded):
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebExtension.mm:
(TEST(WKWebExtension, BackgroundParsing)): Added tests.

Canonical link: https://commits.webkit.org/275916@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to