how to wait for the dom to be fully loaded code example
Example: wait for the dom to load javascript
document.addEventListener('DOMContentLoaded', (event) => {
//the event occurred
})
document.addEventListener('DOMContentLoaded', (event) => {
//the event occurred
})