It was coined by American cartoonist Thomas A Dorgen (1877-1929).
It means 'something considered to be outstanding'. t's 1920s slang similar to the following.
From "Listening to America: An Illustrated History of Words and Phrases from Our Lively and Splendid Past" by Stuart Berg Flexner:
"For 'great' (in the 20s) we have: the cat's pajamas, remarkable, first used around 1920, when pajamas were still somewhat shockingly new...similar expressions...the duck's quack, 1920; the bee's knees, the clam's garters, the elephant's wrist, the eel's ankles, the gnat's elbow, all 1923 the elephant's arches and the sardine's whiskers, both 1924; the bullfrog's beard, the cuckoo's chin, the leopard's stripes, the pig's wings, the snake's hips, and the tiger's spots, all 1 More Related Questions & Answers...