Putting aside the fact that the superhero has clear precedence in myth and legend and the pulp fiction of the early twentieth century, the genesis of the modern superhero begins in the nineteen thirties, between wars, so it is natural to expect a correlation between the two.
Comics, though, with the exception of the Commando war books, rarely deal with the ordinary soldier caught up in a combat situation. Two Fisted Tales did a very good job of this and War Is Hell! with its blend of horror also dealt well with the faceless dread. But when a superhero dons a costume, it is bright and spangly - he wears the flag rather than just representing it. Though note the case of Captain America, who is given both his powers and costume by the government and, when he apparently perishes, is replaced by other patriotic heroes Spirit of '76 and The Patriot. This tradition has continued into modern times when Steve Rogers falls out with the government and is replaced, taking on a new identity as Nomad. This idea of the faceless government operative deployed in the war zone is also shown in the personification of the Unknown Soldier.
Naturally romance is rare in a combat zone and only appeared after the war but other things like fantasy and drama combine successfully with battlefield heroics.
Science fiction can always trot out that evergreen War of the Worlds and the macabre aspect of global conflict is represented by Weird War Tales.
As far as I can tell Jonah Hex is the only character who recalls the fact that the Wild West was the battleground for the American Civil War. By the time we read his adventures he is a bounty hunter but he still wears the Confederate uniform.
Now, hot off the presses, is a graphic depiction of the Civil War itself.
Humour and war would seem to be strange bedfellows but the Bluey and Curly strip proved that it was possible.
And you want reality? Lest we forget, the
War artist. Grunts can grunt all they want but you try facing mortar fire with a stick of charcoal and a HB.