Code Smells & Fault-Proneness

A Replication Study in JavaScript Projects

Comprehensive analysis of the relationship between code smells and fault-proneness across 50 JavaScript projects, expanding on previous research with enhanced datasets and methodologies.

Study Overview

0 JavaScript Projects
0 Code Smell Types
0 Research Questions
0 Million+ Smell Instances

RQ1: Smell Survivability

Investigation of code smell lifespan across JavaScript projects, revealing significant variations in removal patterns and persistence rates across different project types.

RQ2: Fault-Proneness Comparison

Comparative analysis between smelly and non-smelly files showing mixed results: 18 projects favor smelly files, 21 show opposite behavior, 11 show no difference.

RQ3: Individual Smell Impact

Assessment of specific code smells' contributions to fault-proneness, identifying Variable Re-assign, Complex Code, and Assignment in Conditionals as top risk factors.

Key Findings

Top Risk Factors

Variable Re-assign: 34.60% increased fault risk
Complex Code: 31.40% increased fault risk
Assignment in Conditionals: 30.00% increased fault risk

Smell Distribution

Most prevalent smells: Variable Re-assign (3.4M instances), Lengthy Lines (3.1M), and Chained Methods (1.4M) represent the majority across analyzed codebases.

Survivability Patterns

32 projects show high removal rates (>70%), 10 show low removal (<45%), 8 show moderate removal. Mean survivability ranges from 59 days to 3,350 days.

Interactive Risk Assessment

Explore Code Smell Risk Levels

Click on different code smells to see their associated fault-proneness risk levels

Current Risk Level: 34.6%
High impact - Most critical smell type

Dataset Information

Project Selection Criteria

We analyzed 50 JavaScript projects selected from GitHub using systematic criteria:

  • Minimum 864 stars (median: 14,900)
  • Active development with regular commits
  • Substantial codebase (3K - 1.2M LOC)
  • Diverse application domains
  • Community engagement (39-836 contributors)
0 Average LOC (K)
0 Average Contributors
0 Average Stars (K)
0 Average Issues

Replication Package

Raw Dataset

Complete dataset with smell instances, project metadata, and fault information for all 50 projects

Download CSV

Research Paper

Full research paper with detailed methodology, results, discussion, and threats to validity

Read Paper