chromium/third_party/blink/web_tests/http/tests/security/postMessage/resources/javascript-post-message-sender.html

<!DOCTYPE html>
<html>
<body onload="nav()">
<script>
function nav() {
    var url = "javascript:'<script>" + 
      "top.postMessage(\"Hello from child\", \"*\");" + 
      "document.write(\"Message sent\");" +
      "</scri" + "pt>'";

    window.location.href = url;
}
</script>
Sending...
</body>
</html>