interplane.Get Omega
Read in your language

aienos.com

Source of www.aienos.com, served from my own hardware

Brought by drakestapleton

branch main Branches Tags History

aienos.com / public / js / aien-run.js

16 lines · 739 bytes Raw Blame History
1/* The program runner (/aien/run.html, components::csp). The Aien page frames
2 this document sandboxed to allow-scripts and posts one program; it is
3 written here, where the policy allows inline scripts. Nothing is written
4 unless this document has an opaque origin (a sandboxed frame) and the
5 message comes from the framing page. document.open() drops this listener,
6 so a document is written once. */
7(() => {
8 if (self.origin !== 'null' || parent === self) return;
9 document.documentElement.style.visibility = 'hidden';
10 addEventListener('message', event => {
11 if (event.source !== parent || typeof event.data !== 'string') return;
12 document.open();
13 document.write(event.data);
14 document.close();
15 });
16})();