1.首先,打开电脑控制面板,搜索“字体”,然后打开
2.
2.选择自己喜欢的字体,复制到桌面,将TTF格式字体转换为WOFF格式,方法有很多,推荐一种方式,连接地址:https://convertio.co/zh/font-converter/
3.网站调用:
@font-face
{
font-family
: myFirstFont; //字体名称
src
:
url
(sansation_light.woff); //字体存放路径
}
<div style=
"font-family: myFirstFont;"
> //应用字体
我的字体
</div>