Why is this F/A-18 flying through a hailstorm of sparkles? The F/A-18 Super Hornet squadron VF-102 Diamondbacks, flying from the USS Ronald Reagan, has posted a montage video of its 2019 Indo-China cruise.
At about 5:15, the video shows a night-time cockpit view of the aircraft flying through a shower of sparks. There is also the view looking backwards. It's like a sci-fi special-effect.

                
            
What would cause this phenomenon?

source - YouTube
The sparks in the video come from the F-18's Vulcan cannon being fired at night.
During daytime you'd only see muzzle flash accompanied by a pretty puff of smoke. Low light conditions bring out the sparks, or rather, residual gunpowder still burning (or glowing) as it exits the barrel.