Answers for "css text gradient and shadow"

CSS
6

gradient text shadow css

h1 {
    position: relative;
}

h1::after {
    background-image: linear-gradient(#f00, #fcc);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    content: attr(data-content);
    position: absolute;
    top: 0;
    left: 0;
}

h1::before {
    text-shadow: #000 1px 1px 2px;
    content: attr(data-content);
    position: absolute;
    top: 0;
    left: 0;
}
Posted by: Guest on August-27-2021

Browse Popular Code Answers by Language