My understanding of the "common wisdom" is that Shakespeare wrote the lyrics for the songs in his plays, and others wrote the music. There is no certainty about what melodies were used because all such information disappeared during the Puritan Nightmare, when the theatres were closed for decades. There is a widespread tradition that the melody commonly used for "The Wind and the Rain" from Twelfth Night is "original" i.e. is the one used when the King's Men performed the show for the first time. Virtually all the other melodies have been composed since the Restoration for specific productions.
|