misc refactors

This commit is contained in:
velzie 2024-08-31 11:01:51 -04:00
parent 819c1701d0
commit 0939dd2b57
No known key found for this signature in database
GPG key ID: 048413F95F0DDE1F
25 changed files with 82 additions and 66 deletions

View file

@ -1,7 +1,7 @@
// @ts-nocheck
import { ScramjetClient } from "./client";
import { nativeGetOwnPropertyDescriptor } from "./natives";
import { encodeUrl, decodeUrl } from "./shared";
import { encodeUrl, decodeUrl } from "../shared";
export function createLocationProxy(
client: ScramjetClient,
@ -39,7 +39,7 @@ export function createLocationProxy(
apply(target, thisArg, args) {
let url = new URL(client.url.href);
url[prop] = args[0];
self.location.href = encodeUrl(url.href);
client.url = url;
},
});
}