Last active
February 2, 2021 20:51
-
-
Save cvan/4f1f77afc7918fb77bb7a2f71d0f3e0b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(() => { | |
const width = window.outerWidth / 2; | |
const height = window.outerHeight / 2; | |
const top = 0; | |
const left = width * 3; | |
const popupEl = window.open('http://example.com', 'preview', `height=${height},width=${width},scrollbars=yes,left=${left},top=${top}`); | |
popupEl.focus(); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment