AdguardTeam / AdguardTeam/Scriptlets

Improve cookie scriptlets — support 'CookieStore' API

Offen
#521 0 Kommentare 3 Reaktionen 1 zugewiesene Person Beansprucht von @maximtop Auf GitHub ansehen
enhancement Priority: P4
Vorherrschende Sprache
JavaScript
Sterne
195
Forks
33
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Current description is just a bare MDN link. Needs full expansion:

The following cookie-related scriptlets currently access cookies only via `document.cookie` (synchronous string manipulation):
`set-cookie`, `set-cookie-reload`, `trusted-set-cookie`, `trusted-set-cookie-reload`.

The [CookieStore API](https://developer.mozilla.org/en-US/docs/Web/API/CookieStore) is a newer async alternative that provides cleaner access to cookies without string parsing, and properly handles `SameSite`/`Secure` attributes.

When `CookieStore` is available (currently Chrome/Edge), scriptlets should use it instead of `document.cookie` to set cookies.

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.