Hi dear welcome to Ascode Blog . In this post we are going to learn css text-stroke property uses. First Creat A index.html file Copy This HTML CODE and pest it one your code editor. 2ndly creat style.css file Then Copy The CSS CODE and pest it then open the index.html file with your browser.
HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>css text-stroke</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="container">Ascode</div>
</body>
</html>
CSS
<style>
.container {
font-family: sans-serif;
color: transparent;
width: fit-content;
background: #111;
padding: 20px 30px;
font-weight: bold;
font-size: 10rem;
/* stroke property */
-webkit-text-stroke:2px #fff;
text-transform: uppercase;
}
0 Comments