js js 파일로 만들어서 html에 불러오기 const remainTime = document.querySelector("#remain-time"); function diffDay() { const masTime = new Date(); //시작일 const todayTime = new Date("2022-12-01"); // 오늘 const diff = masTime - todayTime; const diffDay = String(Math.floor(diff / (1000*60*60*24))); const diffHour =String( Math.floor((diff / (1000*60*60)) % 24)).padStart(2,"0"); const diffMin = String(Math.floor((..