Computer >> Computer tutorials >  >> Programming >> CSS

How to define the location of a font for download in CSS


The @font-face rule is used to define the location of a font for download, although this may run into implementation-specific limits.

Example

Let us see an example

<style>
   <!--
      @font-face {
         font-family: "Scarborough Light";
         src: url("https://www.font.site/s/scarbo-lt");
      }
      @font-face {
         font-family: Santiago;
         src: local ("Santiago"),
         url("https://www.font.site/s/santiago.tt")
         format("truetype");
         unicode-range: U+??,U+100-220;
         font-size: all;
         font-family: sans-serif;
      }
   -->
</style>