perf: use astro Image optimization
This commit is contained in:
parent
6c9f475593
commit
ad56b4d22e
2 changed files with 9 additions and 1 deletions
|
@ -5,6 +5,9 @@ import sitemap from '@astrojs/sitemap'
|
||||||
// https://astro.build/config
|
// https://astro.build/config
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
site: 'https://ayo.ayco.io',
|
site: 'https://ayo.ayco.io',
|
||||||
|
image: {
|
||||||
|
domains: ['cdn.bsky.app'],
|
||||||
|
},
|
||||||
integrations: [
|
integrations: [
|
||||||
sitemap(),
|
sitemap(),
|
||||||
serviceWorker({
|
serviceWorker({
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
---
|
---
|
||||||
import { Code } from 'astro:components'
|
import { Code } from 'astro:components'
|
||||||
|
import { Image } from 'astro:assets'
|
||||||
import Footer from '../components/Footer.astro'
|
import Footer from '../components/Footer.astro'
|
||||||
import Layout from '../layouts/Layout.astro'
|
import Layout from '../layouts/Layout.astro'
|
||||||
import importedCode from '../../public/following_accounts.csv?raw'
|
import importedCode from '../../public/following_accounts.csv?raw'
|
||||||
|
@ -84,9 +85,13 @@ const description =
|
||||||
accountObjects.map((account, index) => (
|
accountObjects.map((account, index) => (
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<img
|
<Image
|
||||||
src={data[index].avatar}
|
src={data[index].avatar}
|
||||||
alt={`${account.bskyHandle}'s avatar`}
|
alt={`${account.bskyHandle}'s avatar`}
|
||||||
|
width="50"
|
||||||
|
height="50"
|
||||||
|
decoding="async"
|
||||||
|
loading="lazy"
|
||||||
/>
|
/>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
|
Loading…
Reference in a new issue