From 7781c69153e3956ca14684fe9a287fbbb8a01082 Mon Sep 17 00:00:00 2001 From: Joe Carstairs <65492573+Sycamost@users.noreply.github.com> Date: Sun, 13 Aug 2023 20:41:29 +0100 Subject: Determines current locale with lib function --- src/components/LallansIssuesGallery.astro | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'src/components/LallansIssuesGallery.astro') diff --git a/src/components/LallansIssuesGallery.astro b/src/components/LallansIssuesGallery.astro index c784156..f3db9b3 100644 --- a/src/components/LallansIssuesGallery.astro +++ b/src/components/LallansIssuesGallery.astro @@ -1,13 +1,8 @@ --- import { getAllLallansIssues } from '$data/lallans'; -import type Locale from '$types/Locale'; - -interface Props { - locale: Locale; -} - -const { locale } = Astro.props; +import getLocaleFromPath from '$lib/getLocaleFromPath'; +const locale = getLocaleFromPath(Astro.url.pathname); const issues = await getAllLallansIssues(); --- -- cgit v1.2.3