Some methods, depending on what the script does (in no particular order): (Then again, some webmasters can be obsessive-paranoids about such things.
This is not foolproof and usually is way too much trouble for the negligible 'threat' to the site. Yes, in theory, a site can deduce the presence of scripts in various situations.