A partial archive of discourse.wicg.io as of Saturday February 24, 2024.

[Question] `self.isolateOrigin()`: Ability for a page or origin to programmatically self-isolate

joe
2022-03-08

I’m wondering if this sort of thing is feasible? The thing that prompted me to post this question was the desire to use wasm threads on a Github Pages website.

Someone has apparently come up with a workaround using service workers, so it seems that a feature like this would even be polyfill-able already? I’d assumed that there was some technical reason that this feature needed to be implemented with headers, but that workaround makes me think that a programmatic “switch” is possible?

simevidas
2022-03-14

Re StackOverflow question

Cross-Origin-Opener-Policy: same-origin
Cross-Origin-Embedder-Policy: require-corp

Can these headers be included in the HTML document via <meta http-equiv> tags?

joe
2022-03-17

No, unfortunately not: html - Can COOP/COEP headers be set with meta tags (http-equiv)? - Stack Overflow

joe
2022-05-15

Wondering if a pro here can comment on the feasibility of a feature like this? I’ve been using the above-mentioned Service Worker hack on Github Pages, and it works, but requires a page reload and in general is just really hacky.

A more concrete question, in case it’s useful for context: Is there any chance we’ll eventually be able to use SharedArrayBuffer on pages where we don’t have control over the headers?