It is a work that enhances code to improve readability, and maintenance, reducing redundant code, leaving the original operation as it is, and making the code more efficient. (동작하는 것은 그대로 두고, 코드 자체를 효율적으로 만들어서, 가독성과 유지보수성을 높이고 중복된 코드를 줄이는 방향으로 코드를 개선하는 작업)
When coding, you need to proceed from time to time.
1.1 this
Keywords belonging to the onclick event, pointing to itself
is referencing index tag(인덱스 태그 참조), delete id="night_day2"
1. Refactoring(리팩토링)
1.1
this
id="night_day2"
Cmd+Shift+L
: Choosing the same wordsA necessary posture: removing overlapping