File tree Expand file tree Collapse file tree 6 files changed +17
-23
lines changed
Expand file tree Collapse file tree 6 files changed +17
-23
lines changed Original file line number Diff line number Diff line change 1- import { defineConfig } from 'astro/config' ;
1+ import { defineConfig , fontProviders } from 'astro/config' ;
22import db from '@astrojs/db' ;
33import preact from '@astrojs/preact' ;
44import sitemap from '@astrojs/sitemap' ;
@@ -31,7 +31,19 @@ export default defineConfig({
3131 inlineStylesheets : 'always'
3232 } ,
3333 experimental : {
34- clientPrerender : true
34+ clientPrerender : true ,
35+ fonts : [
36+ {
37+ provider : fontProviders . google ( {
38+ experimental : { variableAxis : { Inter : { opsz : [ '14..32' ] } } }
39+ } ) ,
40+ name : 'Inter' ,
41+ cssVariable : '--astro-font-inter' ,
42+ weights : [ '300 900' ] ,
43+ styles : [ 'normal' ] ,
44+ subsets : [ 'latin' ]
45+ }
46+ ]
3547 } ,
3648 image : {
3749 remotePatterns : [
Original file line number Diff line number Diff line change 11---
2+ import { Font } from ' astro:assets' ;
23import { ClientRouter } from ' astro:transitions' ;
34import { Schema } from ' astro-seo-schema' ;
45
@@ -93,13 +94,7 @@ const description = Astro.props.description ?? starpodConfig.description;
9394
9495 <link rel =" preload" as =" image" href ={ show .image } />
9596
96- <link
97- crossorigin
98- rel =" preload"
99- href =" /fonts/InterVariable.woff2"
100- as =" font"
101- type =" font/woff2"
102- />
97+ <Font cssVariable =" --astro-font-inter" preload />
10398
10499 <Schema
105100 slot =" head"
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1- @import './fonts.css' ;
21@import './tailwind.css' ;
32@import './gradient-icon.css' ;
43@import './buttons.css' ;
Original file line number Diff line number Diff line change 3636 --color-light-text-body : oklch (59.68% 0.017 285.89 );
3737 --color-light-text-heading : oklch (30.55% 0.052 292.57 );
3838
39- --font-inter : Inter , sans-serif ;
39+ --font-inter : var ( --astro-font-inter ) ;
4040}
4141
4242/*
You can’t perform that action at this time.
0 commit comments