Skip to content

Implement Origin API #41106

@TimvdLippe

Description

@TimvdLippe

Specification: https://html.spec.whatwg.org/multipage/browsers.html#the-origin-interface

To do so, add an Origin.webidl to https://github.com/servo/servo/tree/main/components/script_bindings/webidls which contains the IDL from the specification.

Then, implement the methods on OriginMethods using the same site implementation at

fn is_same_site(site_a: &ImmutableOrigin, site_b: &ImmutableOrigin) -> bool {
and same-origin can be done by comparing two origins with ==.

You can run the tests with ./mach test-wpt /html/browsers/origin/api/ and verify they are passing.

Metadata

Metadata

Labels

A-content/scriptRelated to the script threadC-assignedThere is someone working on resolving the issueE-less-complexStraightforward. Recommended for a new contributor.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions