Here’s another "best practice" type of question for the web worker crowd... what is generally going to result in better performance? Including a few larger files, knowing that maybe you don’t need all the functions in them? Or is it better to pare the files down into smaller files and load the extra functions only as needed?
For example:
Option 1: One large base class with 10 different functions... only half of which I’d use a majority of the time, but for the rest of the time, I wouldn’t have to load other files.
Option 2: Very small base class with only 3 or 4 functions... streamlined use (e.g. barfing out a cache file) requires no additional loading, but other more common options might require that the class loads additional files.
Option 3:
I’m trying to find the balance between having a small footprint and avoiding a performance hit by having to include a bunch of files... surely there’s a happy medium. I don’t even know a good way to test this. Any ideas?