mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-16 23:50:02 -04:00
document.write why not
This commit is contained in:
parent
d707bd7be3
commit
6e9ce2238c
1 changed files with 23 additions and 0 deletions
|
@ -234,4 +234,27 @@ export default function (client: ScramjetClient, self: typeof window) {
|
||||||
return scram.documentProxy;
|
return scram.documentProxy;
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
client.Proxy("document.write", {
|
||||||
|
apply(ctx) {
|
||||||
|
ctx.args[0] = rewriteHtml(
|
||||||
|
ctx.args[0],
|
||||||
|
client.cookieStore,
|
||||||
|
client.meta,
|
||||||
|
true
|
||||||
|
);
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
client.Proxy("document.writeln", {
|
||||||
|
apply(ctx) {
|
||||||
|
// this injects scramjet multiple times but who gaf
|
||||||
|
ctx.args[0] = rewriteHtml(
|
||||||
|
ctx.args[0],
|
||||||
|
client.cookieStore,
|
||||||
|
client.meta,
|
||||||
|
true
|
||||||
|
);
|
||||||
|
},
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue