I am currently reading Ernst Junger's Copse 125, a German account of a period in the trenches in 1918. In it, he claims that early in the war a lot of soldiers wore full beards in homage to their grandfathers of 1871 (translations are my own, from the Spanish translation, Bosquecillo 125, that I am reading), but that the practice was abandoned when gas masks were issued. In fact, a lean, clean shaven face below the shadow of the steel helmet is emblematic of the WW1 warrior for the author.
During the mid-20th century, beards seem to have been massively out of favour. My grandmother, born in 1919, stills considers them (including mine) to be awful, although her sense that beard-wearers are inherently untrustworthy has diminished. I remeber similar sentiements from childhood literature including books by Enid Blyton and Roald Dahl.
So, is there a connection? Was the decline of the beard really affected by the need for gas masks to seal?
You might enjoy this earlier thread about beards, racism. and the perpetual crisis of masculinity, with answers from /u/The_Alaskan and /u/whitesock