Despite being crucial, the performance of web applications is usually not a primary concern. I will present results of an empirical study on performance optimizations in JavaScript conducted on 16 popular JavaScript projects. The study identifies eight root causes of issues and shows that inefficient usage of APIs is the most prevalent root cause. Furthermore, I found that most issues are addressed by optimizations that modify only a few lines of code, without significantly affecting the complexity of the source code. The study also covers the performance impact of optimizations on several versions of popular engines. Finally, I observe that many optimizations are instances of recurring patterns.
enterjs.de