Skip to content

Instantly share code, notes, and snippets.

@munierujp
Last active July 12, 2024 10:47
Show Gist options
  • Save munierujp/d5bf56551828b44d3474479a4c8be6c2 to your computer and use it in GitHub Desktop.
Save munierujp/d5bf56551828b44d3474479a4c8be6c2 to your computer and use it in GitHub Desktop.
const waitLoaded = async () => {
await new Promise((resolve) => {
window.addEventListener('load', () => {
resolve()
})
})
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment