$(document).ready(function(){}); vanilla JS로 대체 DOMContentLoaded
https://euntori7.tistory.com/356 document ready 를 순수 javascript로 jquery를 쓰지 않고 순수 javascript로 ready()를 대체하는 코드. 참고로, $(docum.. euntori7.tistory.com https://developer.mozilla.org/ko/docs/Web/Events/DOMContentLoaded DOMContentLoaded DOMContentLoaded 이벤트는 초기 HTML 문서를 완전히 불러오고 분석했을 때 발생합니다. 스타일 시트, 이미지, 하위 프레임의 로딩은 기다리지 않습니다. developer.mozilla.org document.addEventListener('DOMContentLoaded', functi..