Add EsLint
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
---
|
||||
import { getCollection } from 'astro:content'
|
||||
import { getCollection } from "astro:content";
|
||||
import NavbarLayout from "../../layouts/NavbarLayout.astro";
|
||||
import {astroI18n, createGetStaticPaths} from "astro-i18n";
|
||||
|
||||
@@ -8,14 +8,13 @@ export const getStaticPaths = createGetStaticPaths(async () => {
|
||||
|
||||
return posts.filter(value => value.id.split("/")[0] === astroI18n.locale).map((page) => ({
|
||||
props: { page }, params: { slug: page.slug }
|
||||
}) )
|
||||
})
|
||||
}) );
|
||||
});
|
||||
|
||||
const { page } = Astro.props;
|
||||
const { Content } = await page.render();
|
||||
---
|
||||
|
||||
|
||||
<NavbarLayout title={page.data.title}>
|
||||
<article>
|
||||
<h1 class="text-left">{page.data.title}</h1>
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
import {getCollection} from "astro:content";
|
||||
import {astroI18n} from "astro-i18n";
|
||||
|
||||
import NavbarLayout from "../../layouts/NavbarLayout.astro";
|
||||
import {l} from "../../util/util";
|
||||
import PageLayout from "../../layouts/PageLayout.astro";
|
||||
let posts = await getCollection("help", entry => entry.id.split("/")[0] === astroI18n.locale);
|
||||
@@ -13,9 +12,9 @@ let posts = await getCollection("help", entry => entry.id.split("/")[0] === astr
|
||||
<h1>Helpcenter</h1>
|
||||
<h1 class="text-red-700 text-4xl">WIP!</h1>
|
||||
{posts.map(value => (
|
||||
<a href={l("/help/" + value.slug)}>
|
||||
<h2>{value.data.title}</h2>
|
||||
</a>
|
||||
<a href={l("/help/" + value.slug)}>
|
||||
<h2>{value.data.title}</h2>
|
||||
</a>
|
||||
))}
|
||||
</div>
|
||||
</PageLayout>
|
||||
|
||||
Reference in New Issue
Block a user