The font-variant property in
Note: Small-caps font is used to convert all the lowercase letters into upper case, but the font size of converted letters is smaller than the original uppercase letters.
font-variant: normal|small-caps|initial|inherit;
normal: It is the default value. It is used to display the normal font.
small-caps: It is used to display the small-caps font by the browser.
initial: It sets the value to its default value.
inherit: It inherits the property from its parent value.
The basic font-variant property is as follows:
In this example, we set the font-variant property as small caps. In the output, all the lowercase letters are converted into uppercase letters. However, there is a difference in the font size of converted alphabets. We can set the property as per our requirements.