Self-host fonts for improved performance
- Download JetBrains Mono and Pretendard fonts (woff2) - Add fonts.css with @font-face declarations - Remove Google Fonts external dependencies - Update CSP to remove fonts.googleapis.com - Update all HTML files to use local fonts Improves FCP/LCP by eliminating external font requests. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
44
fonts.css
Normal file
44
fonts.css
Normal file
@@ -0,0 +1,44 @@
|
||||
/* JetBrains Mono - Regular (400) */
|
||||
@font-face {
|
||||
font-family: 'JetBrains Mono';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
src: url('/fonts/jetbrains-mono-400.woff2') format('woff2');
|
||||
}
|
||||
|
||||
/* JetBrains Mono - Bold (700) */
|
||||
@font-face {
|
||||
font-family: 'JetBrains Mono';
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
font-display: swap;
|
||||
src: url('/fonts/jetbrains-mono-700.woff2') format('woff2');
|
||||
}
|
||||
|
||||
/* Pretendard - Regular (400) */
|
||||
@font-face {
|
||||
font-family: 'Pretendard';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
src: url('/fonts/pretendard-400.woff2') format('woff2');
|
||||
}
|
||||
|
||||
/* Pretendard - SemiBold (600) */
|
||||
@font-face {
|
||||
font-family: 'Pretendard';
|
||||
font-style: normal;
|
||||
font-weight: 600;
|
||||
font-display: swap;
|
||||
src: url('/fonts/pretendard-600.woff2') format('woff2');
|
||||
}
|
||||
|
||||
/* Pretendard - Bold (700) */
|
||||
@font-face {
|
||||
font-family: 'Pretendard';
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
font-display: swap;
|
||||
src: url('/fonts/pretendard-700.woff2') format('woff2');
|
||||
}
|
||||
Reference in New Issue
Block a user