Merge pull request #16 from Fluffy-Bean/deepsource-transform-2b9ebd1b

style: format code with Prettier
This commit is contained in:
Michał 2024-05-28 21:37:47 +01:00 committed by GitHub
commit 3592650efc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 22 additions and 18 deletions

View file

@ -5,12 +5,12 @@ import mdx from "@astrojs/mdx";
// https://astro.build/config
export default defineConfig({
output: "static",
markdown: {
syntaxHighlight: "shiki",
shikiConfig: {
theme: syntaxTheme
}
},
integrations: [mdx()]
});
output: "static",
markdown: {
syntaxHighlight: "shiki",
shikiConfig: {
theme: syntaxTheme,
},
},
integrations: [mdx()],
});

View file

@ -3,22 +3,24 @@ title: Astro is hard....
description: Arugh
pubDate: 2024-05-28
tags:
- astro
- typescript
- astro
- typescript
---
import Note from "../../components/Note.astro";
<Note text="I have no clue what I'm doing :3" />
- I've been trying to learn typescript through trying astro
- Astro is hard, due to all the issues I've encountered
- I've been trying to learn typescript through trying astro
- Astro is hard, due to all the issues I've encountered
```typescript
export async function getTagsBySlug(postTags: string[]): Promise<CollectionEntry<"tags">[]> {
export async function getTagsBySlug(
postTags: string[],
): Promise<CollectionEntry<"tags">[]> {
// Collect all the tags from collections
const allTags: CollectionEntry<"tags">[] = await getCollection("tags");
// Loop through all the tags in a post and the tags in the collections
// To see if they match, if they do we'll return them
const tags: CollectionEntry<"tags">[] = [];
@ -27,7 +29,7 @@ export async function getTagsBySlug(postTags: string[]): Promise<CollectionEntry
if (allTag.slug === postTag) tags.push(allTag);
});
});
// Yeet
return tags;
}

View file

@ -30,10 +30,12 @@
}
// If its a clickable element
a.pill, button.pill {
a.pill,
button.pill {
text-decoration: none;
&:hover, &:focus-visible {
&:hover,
&:focus-visible {
border: 2px solid $accent;
background-color: rgba($accent, 0.1);
outline: 0 solid transparent;