What is irony in poetry?

man wearing welding helmet welding metal near gray brick wall
Photo by Movidagrafica Barcelona on Pexels.com

https://www.poetryfoundation.org/learn/glossary-terms/irony

 

“As a literary device, irony implies a distance between what is said and what is meant. Based on the context, the reader is able to see the implied meaning in spite of the contradiction. When William Shakespeare relates in detail how his lover suffers in comparison with the beauty of nature in “My Mistress’ Eyes Are Nothing like the Sun,” it is understood that he is elevating her beyond these comparisons; considering her essence as a whole, and what she means to the speaker, she is more beautiful than nature. “