do you know how I can read the size of an imported Illustrator Asset before I actually place it into a frame in InDesign? (I know I can access the size by calling the geometricBounds of the frame/rectangle I place it in, after setting the fit to frameToContent, but I would like to have that information BEFORE I place it)
I can't think of any way to do that other than reading the file directly or at least reading the XMP data in the file (if there is any).
You may be able use file.readIn() until you find lines starting with…
%%BoundingBox: 35 26 255 250
%%HiResBoundingBox: 35.0581 26.1602 254.4854 249.7837