Introduction
The <i>
element in HTML is used to represent text that is set in italic or emphasized style. However, it’s important to note that in HTML5, the <i>
element is considered a presentational element, and its use is often discouraged in favor of more semantically meaningful alternatives.
Example:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Necessitatibus aliquid, vero, <i>fugit enim suscipit adipisci, ad rerum fuga libero obcaecati aperiam id reprehenderit optio?</i> Laborum debitis blanditiis aperiam dolorem exercitationem.</p>
</body>
</html>
Output :
Anything we write in ‘<i>‘ tag it will show in italic style just look like in above image.