I don't know about the F-18, but on the 787 there is a copper wire mesh incorporated into the composite layup during build to improve the electrical resistance and hence improve it's lightning protection.
And similar arrangement on the A-6 carbon fiber re- wings built by Boeing a few decades ago . There was/and is a lot of public available papers and research on lightning strike protection on carbon fiber structural panels and the effects. And there is also a limited amount of related published information on an virtually all fiber ' paneled ' military airplane built in the 80's - a 3 foot model of which is on a pedestal across the street from the " Red Barn " portion of the Museum of Flight
wuztheredunthat
And although it is not me- the following link may be of help explaining
https://patents.google.com/patent/US20050213278