0

I am working on a rails project that has too many javascript files. Processing this script takes too much time. I want to remove the unnecessary javascript includes from my application. I am familiar with the plugins that can find unnecessary css but I haven't come across any method of finding unused javascript. If anyone has any idea regarding this please share.

Thanks

1 Answer 1

0

Are you referring to rjs (Rails-generated) or standard js files? If it's the latter then you can use jslint. For the first type you should have some integration tests that fail when you remove the RJS that is being used, if not you'll have to add those tests first.

For more see: Is there a tool to remove unused methods in javascript?

Sign up to request clarification or add additional context in comments.

1 Comment

I have tried jslint but it does not tell me the files that are unused rather it displays the errors associated with the js code

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.