Repository navigation
Remove static-host header shim - #8
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR removes the service-worker-based header shim previously used to “force” cross-origin isolation on static hosts, and updates CI/tests/docs to rely on the deployment environment providing real COOP/COEP/CORP headers.
Changes:
- Removed
enable-threads.jsand its inclusion from the example page so missing isolation headers fail visibly. - Updated README deployment guidance to require host-provided isolation headers and clarified GitHub Pages limitations.
- Removed the Netlify deploy job from CI and deleted the browser E2E test that validated the Pages-like shim behavior.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| README.md | Updates deployment/docs to remove the header-shim narrative and require real isolation headers from the hosting layer. |
| example/index.html | Removes the script include for the service-worker header shim. |
| example/enable-threads.js | Deletes the service worker used to inject COOP/COEP headers on static hosts. |
| browser_e2e_test.go | Removes the Pages-like browser test that depended on the shim-induced isolation behavior. |
| .github/workflows/ci.yml | Removes the Netlify production deploy job from CI. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+387
to
+388
| The host in front of the built `./example` directory must set the OPFS headers | ||
| on every response: |
sputn1ck
force-pushed
the
kon/remove-static-host-header-shim
branch
from
June 27, 2026 09:25
2caabd6 to
a13c250
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
enable-threads.js)lightning.community/go-wasmsqliteis expected to provide real COOP/COEP/CORP headersNotes
If
lightning.community/go-wasmsqlite/serves real isolation headers, the service-worker shim is unnecessary and should be removed so missing headers fail visibly. The current same-location 301 loop happens before demo JavaScript loads, so it must be fixed at the route/origin layer.Testing
go test ./...make build-wasmcd example && GOOS=js GOARCH=wasm go build -o main.wasm .WASM_BROWSER_TEST=1 go test -run TestBrowserE2E ./...