@font-face src:local() does not work on some fonts like Fira Code, but it works fine on other fonts like Comic Sans MS. Am i missing something?
Fira Code:
<!DOCTYPE html>
<html>
<head>
<style>
@font-face {
font-family: 'Custom';
src: local('Fira Code');
}
.font {
font-family: 'Fira Code';
}
.font-face {
font-family: 'Custom';
}
</style>
</head>
<body>
<p>Fira Code: <span class="font">hijklmn</span></p>
<p>Fira Code(@font-face): <span class="font-face">hijklmn</span></p>
</body>
</html>
Chrome 91.0.4472.164:
Firefox 90.0:
Comic Sans MS:
<!DOCTYPE html>
<html>
<head>
<style>
@font-face {
font-family: 'Custom';
src: local('Comic Sans MS');
}
.font {
font-family: 'Comic Sans MS';
}
.font-face {
font-family: 'Custom';
}
</style>
</head>
<body>
<p>Comic Sans MS: <span class="font">hijklmn</span></p>
<p>Comic Sans MS(@font-face): <span class="font-face">hijklmn</span></p>
</body>
</html>
Chrome 91.0.4472.164:
Firefox 90.0:
More information:
- OS: Windows 10
Fira Codeis installed through.ttffilesFira Codecan be used in any editor.




