Thanks to all for this excellent discussion about
To Shane’s point, I think it makes a difference whether you are writing code for a client to use in a production environment, or in writing code for yourself (and maybe a few friends/colleagues) to use in your/their personal Mac.
It also depends on the type of scripts you will be writing. I’m at the point where many, if not most, of my scripts will directly, or via handlers/script libraries, use ASObjC.
So, since Shane has told us:
I feel comfortable in using a standard set of
use statements, not knowing for sure if I will need all of them or not. So, I think I will stick with my default setup:
use AppleScript version "2.5" -- El Capitan (10.11) or later
use framework "Foundation" -- this may not be required
use framework "AppKit" -- this may be not be required
use scripting additions
## Some Scripts may work with Yosemite, but no guarantees ##
# This script has been tested ONLY in macOS 10.11.6+
If at some point in the future I find that including one of these that isn’t required causes a problem, then I will adjust accordingly.