A place where you can find useful information about Unity.
Here is an example of how to export multiple objects and their asset dependencies without automatically including all scripts.
Assume you have a Player prefab and an Enemy prefab, each with their respective components, meta-data, and scripts. You want to export them both into one package but not include every single script in your project (without having to manually uncheck a large number of scripts from the export dialog).