forked from cms/tibi-svelte-starter
Content Collection um Tags ChipArray erweitert, um eine Möglichkeit zu schaffen, Stichworte zum Verknüpfen der Seiten zwischen den Sprachen zu schaffen...(WIP)
This commit is contained in:
@@ -186,10 +186,10 @@ export const sendEmail = async (type: string = "contactForm", data: any, noToken
|
||||
})
|
||||
}
|
||||
|
||||
export const getContent = async (path: string, lang: string): Promise<Content> => {
|
||||
export const getContent = async (path: string, lang: string, filter?: APIParams): Promise<Content> => {
|
||||
const c = await api<Content[]>("content", {
|
||||
limit: 1,
|
||||
filter: { path, locale: lang },
|
||||
filter: { path, locale: lang, ...filter },
|
||||
})
|
||||
if (c?.data?.length) {
|
||||
return c.data[0]
|
||||
|
||||
Reference in New Issue
Block a user