Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Find unused Javascript functions?

Tags:

javascript

I have around 100 .js files in my application. I need to find the unused functions from these files.

Which editor or tool can help me?

like image 992
user143442 Avatar asked Jul 23 '09 06:07

user143442


People also ask

How do I see unused js in Chrome?

Detect unused JavaScript #The Coverage tab in Chrome DevTools can give you a line-by-line breakdown of unused code. The Coverage class in Puppeteer can help you automate the process of detecting unused code and extracting used code.

How do I reduce unused JavaScript?

If your website is running on WordPress, you can remove the unused JavaScript from its pages using special plugins. For example, you can use AssetCleanUp, which also allows you to disable unused JavaScript files. Another option is to detect unused JS with Chrome DevTools and delete unnecessary files.


1 Answers

Give a look to the JSLint code quality tool.

like image 52
Christian C. Salvadó Avatar answered Oct 11 '22 09:10

Christian C. Salvadó