mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-13 22:40:01 -04:00
refactor: delete codecs/ & self.$scramjet
This commit is contained in:
parent
f8d33a207e
commit
337134bcdc
22 changed files with 148 additions and 206 deletions
|
@ -5,7 +5,7 @@ import { rewriteUrl } from "../../shared/rewriters/url";
|
|||
export default function (client: ScramjetClient, self: Self) {
|
||||
const Function = client.natives.Function;
|
||||
|
||||
self[config.importfn] = function (base: string) {
|
||||
self[config.globals.importfn] = function (base: string) {
|
||||
return function (url: string) {
|
||||
const resolved = new URL(url, base).href;
|
||||
|
||||
|
@ -15,7 +15,7 @@ export default function (client: ScramjetClient, self: Self) {
|
|||
};
|
||||
};
|
||||
|
||||
self[config.metafn] = function (base: string) {
|
||||
self[config.globals.metafn] = function (base: string) {
|
||||
return {
|
||||
url: base,
|
||||
resolve: function (url: string) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue