window-open-size.html 227 B

123456789
  1. <html>
  2. <body>
  3. <script type="text/javascript" charset="utf-8">
  4. var size = require('electron').remote.getCurrentWindow().getSize();
  5. window.opener.postMessage('size: ' + size[0] + ' ' + size[1], '*')
  6. </script>
  7. </body>
  8. </html>