use Fragment to treat strings as html

allows links in news about emma to function as
URLs and not just text
This commit is contained in:
emma 2025-02-21 06:32:08 -05:00
parent 3c611b38b3
commit 58d38a26c0

View File

@ -8,9 +8,9 @@ const textColorNightMode = "#f1dac4";
const linkColorNightMode = "#4cc9f0";
const emmaNews = [
`01-16-2025 - i'm focusing on studying and trying to get used to the idea of pursuing interests because i can. i wrote a blog post today about how hard the concept is to me`,
`01-23-2025 - i'm working on moving my blog to blog.emmas.place it is hosted on weblog.lol, a part of the omg.lol service`,
`02-20-2025 - i've been spending time learning how to use astro instead of handcoding my site. with time there will be a lot here. i like the way content is managed in astro`
`<li>01-16-2025 - i'm focusing on studying and trying to get used to the idea of pursuing interests because i can. i wrote a blog post today about how hard the concept is to me</li>`,
`<li>01-23-2025 - i'm working on moving my blog to <a href="https://blog.emmas.place">blog.emmas.place</a> it is hosted on <a href="https://weblog.lol">weblog.lol</a>, a part of the <a href="https://omg.lol">omg.lol</a> service</li>`,
`<li>02-20-2025 - i've been spending time learning how to use astro instead of handcoding my site. with time there will be a lot here. i like the way content is managed in astro</li>`
];
---
@ -66,7 +66,7 @@ const emmaNews = [
<h3>news about emma</h3>
<ul>
{emmaNews.map((news) => <li>{news}</li>)}
<Fragment set:html={emmaNews.map((news) => news)} />
</ul>
</BasicLayout>
</body>