Skip to content

update: switch to scramjet v2.0.67#579

Closed
sylvieisnton wants to merge 1 commit into
masterfrom
soap
Closed

update: switch to scramjet v2.0.67#579
sylvieisnton wants to merge 1 commit into
masterfrom
soap

Conversation

@sylvieisnton

Copy link
Copy Markdown
Collaborator

test the changes before merging 🙏

Copilot AI review requested due to automatic review settings June 3, 2026 14:28

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the proxy front-end/runtime to use Scramjet v2.0.67 (via scramjet-controller) and consolidates service-worker handling so Scramjet routing can coexist with Ultraviolet (including an optional blacklist SW).

Changes:

  • Upgrade Scramjet to 2.0.67-alpha.1 and add @mercuryworkshop/scramjet-controller, adjusting build/asset routing to serve the new controller artifacts.
  • Replace the old Scramjet v1 bundled SW scripts with a combined SW (views/sw.js) and a combined blacklist SW (views/sw-blacklist.js) that route Scramjet first, then UV.
  • Update client pages and common logic to initialize the new Scramjet controller + frame navigation model (using an internal sj: target tag).

Reviewed changes

Copilot reviewed 22 out of 24 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
views/uv/WWError.js Removes Workerware error helper (no longer used).
views/uv/workerware.js Removes Workerware middleware implementation.
views/uv/sw-blacklist.js Removes UV-only blacklist SW in favor of combined SW.
views/sw.js Adds Scramjet-first combined SW routing, then UV.
views/sw-blacklist.js Adds combined SW with domain blacklist for Scramjet + UV routing.
views/scram/scramjet.sw.js Removes Scramjet v1 SW script.
views/scram/scramjet.sw-blacklist.js Removes Scramjet v1 blacklist SW script.
views/scram/scramjet.all.js Removes large Scramjet v1 bundle from repo.
views/pages/proxnav/ultraviolet.html Loads new Scramjet + controller API scripts alongside UV.
views/pages/proxnav/scramjet.html Switches from scramjet.all.js to scramjet.js + controller.api.js.
views/pages/proxnav/preset/youtube.html Switches to new Scramjet + controller API scripts.
views/pages/proxnav/preset/applications.html Switches to new Scramjet + controller API scripts.
views/pages/nav/partners.html Switches to new Scramjet + controller API scripts.
views/pages/nav/games.html Switches to new Scramjet + controller API scripts.
views/pages/frame.html Switches to new Scramjet + controller API scripts.
views/assets/js/register-sw.js Refactors initialization to register combined SW and initialize Scramjet controller + frame using transports.
views/assets/js/common-1778310233.js Updates “stealth” navigation to use sj: targets and controller frame navigation; refactors Scramjet autocomplete path.
TODO.md Updates TODO list items (includes new Firefox/testing note).
src/source-rewrites.mjs Adjusts string escaping regex used by the build-time rewriter.
src/server.mjs Adds explicit routes to serve SW files at root-level with Service-Worker-Allowed.
src/routes.mjs Updates SEO/non-SEO file aliases for new Scramjet/controller artifacts and new SW filenames.
run-command.mjs Updates build pipeline to pull Scramjet + controller assets from node_modules and adjust minification inputs.
pnpm-lock.yaml Updates lockfile for Scramjet v2 + controller and transport version bumps.
package.json Bumps transports, pins Scramjet v2 alpha, adds scramjet-controller.
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

// Should help avoid confusion when using or adding to the goProx object.
(url, mode) => {
if (!url) return;
if (parser === sjUrl) mode = 'stealth';
Comment thread views/sw-blacklist.js
Comment on lines +10 to +18
const blacklist = {};
fetch('{{route}}{{/assets/txt/blacklist.txt}}').then((request) => {
request.text().then((textData) => {
textData
.split('\n')
.filter((domain) => domain.trim())
.forEach((domain) => {
const domainTld = domain.replace(/.+(?=\.\w)/, '');
if (!blacklist.hasOwnProperty(domainTld)) blacklist[domainTld] = [];
Comment thread views/sw-blacklist.js
Comment on lines +38 to +39
blacklist.hasOwnProperty(domainTld) &&
blacklist[domainTld].test(domain.slice(0, -domainTld.length))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants