Comment by russellbeattie
8 hours ago
Instead of:
<script>document.currentScript.replaceWith(new Date().getFullYear())</script>
How about:
<svg onload="this.outerHTML=new Date().getFullYear()"/>
Not as pretty, and you'd have to escape all the quotes, but still pretty usable.
Hm, does document.write("...") still exist?
That won't work with trusted types enabled.
Well this works too: