views:

344

answers:

4

I inherited a web site project that includes mootools.js (about 40k) in most of the scripts. However, I have not seen, intuitively, where it is being used and given the nature of this porject, ahem, I'm thinking it might not be being used at all!

I'm "under the gun" to ship this tonight (yup, it's a pre-Thanksgiving release). I have not used mootools.js so I'm not sure what to grep for or if there's a sure tell way to determine this. I don't want to have to JSLint it (or do I LOL). Any suggestions would be appreciated. Thanks.

+2  A: 

Remove it and see if anyone complains.

(You could try it on a test machine first, if you're not feeling brave.)

Mark Byers
+4  A: 

Mootools grafts itself onto some of the native js stuff, so it might be hard to do just by code inspection unless you are very familiar with what MooTools gives you.

Remove it, run your automated tests.

Cause you have those, right?...

SquareCog
A: 

You must have a dev version of the site. Just pull it out and go over pages see if stuff breaks. Mostly you will get unknown function type stuff, if there is any dependencies. Firebug is your friend.

Pavel Zaitsev
A: 

1, Open firebug 2, Click the DOM tab 3, Check if the Mootools object exists (It will say the current version of mootools next to it). Hope this helps :)

The Web Savant