Recap: What is ShadowRealm?
A mechanism to execute JavaScript code within the context of a new global object and set of built-ins.
Goal is not security, but integrity: complete control over the execution environment.
globalThis.someValue = 1;
const realm = new ShadowRealm();
realm.evaluate(`globalThis.someValue = 2;`);
console.assert(globalThis.someValue === 1);