상세 보기
An Empirical Study on Rule Violation History of JavaScript Code Blocks on Stack Overflow
- Kim, Jungil;
- Lee, Eunjoo
WEB OF SCIENCE
1SCOPUS
1초록
JavaScript code blocks on Stack Overflow (SO) are often used in software projects. However, little is known about the issue of rule violation risk in SO JavaScript code blocks. Rule violation is one of the factors which degrades the quality of Java Script code. To prevent prevalence of rule violation by reusing SO JavaScript code blocks, it is needed to investigate how secure SO JavaScript code blocks are against rule violation. To examine the issue, we performed a quantitative analysis to investigate how many rule violations are, when first rule violation occurs and what is the trend of rule violations in evolution history of Stack Overflow JavaScript code blocks. We collected SO posts related to JavaScript and extracted the code blocks contained in the posts. By using ESLint, the most popular rule violation detection tool, we identified rule violations in the evolution history of our target code blocks. We then performed quantitative analyses on the identified rule violations. As the results of the analyses, we found that: (1) 60% of the studied code blocks evolve with any rule violations. (2) In the rule violated code blocks, 92% of the code blocks get first rule violation occurrence in the early phase of their evolution. (3) 80% of the rule violated code blocks never fix existing rule violations during their evolution. Our findings suggest that SO should provide a policy which can reduce rule violations in submitted JavaScript code blocks. The findings can also make SO users attend to rule violations when reusing SO JavaScript code blocks.
키워드
- 제목
- An Empirical Study on Rule Violation History of JavaScript Code Blocks on Stack Overflow
- 저자
- Kim, Jungil; Lee, Eunjoo
- 발행일
- 2022-05
- 유형
- Article
- 권
- 32
- 호
- 05
- 페이지
- 693 ~ 712
- 언어
- ENG
- 출판사
- WORLD SCIENTIFIC PUBL CO PTE LTD
- 발행국가
- 싱가포르
- 분량
- 20 페이지
- ISSN
- E 1793-6403
P 0218-1940