summaryrefslogtreecommitdiffstats
path: root/src/utils
diff options
context:
space:
mode:
authorArmand Philippot <git@armandphilippot.com>2022-01-11 16:20:59 +0100
committerArmand Philippot <git@armandphilippot.com>2022-01-11 16:20:59 +0100
commit606461f857e06b06429dd5738be642f9d1b459be (patch)
treeb8cd9a8fae669ecdf74f52deae4c54ef820c1470 /src/utils
parent99014e5634c6216173bf90117750f95172924134 (diff)
chore: add title and meta desc to subjects and thematics
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/helpers/format.ts15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/utils/helpers/format.ts b/src/utils/helpers/format.ts
index e628369..b79daef 100644
--- a/src/utils/helpers/format.ts
+++ b/src/utils/helpers/format.ts
@@ -84,6 +84,7 @@ export const getFormattedSubject = (rawSubject: RawSubject): Subject => {
featuredImage,
id,
modified,
+ seo,
title,
} = rawSubject;
@@ -103,6 +104,7 @@ export const getFormattedSubject = (rawSubject: RawSubject): Subject => {
intro: contentParts.beforeMore,
officialWebsite: acfSubjects.officialWebsite,
posts,
+ seo,
title,
};
@@ -115,8 +117,16 @@ export const getFormattedSubject = (rawSubject: RawSubject): Subject => {
* @returns A formatted thematic.
*/
export const getFormattedThematic = (rawThematic: RawThematic): Thematic => {
- const { acfThematics, contentParts, databaseId, date, id, modified, title } =
- rawThematic;
+ const {
+ acfThematics,
+ contentParts,
+ databaseId,
+ date,
+ id,
+ modified,
+ seo,
+ title,
+ } = rawThematic;
const dates = {
publication: date,
@@ -132,6 +142,7 @@ export const getFormattedThematic = (rawThematic: RawThematic): Thematic => {
id,
intro: contentParts.beforeMore,
posts,
+ seo,
title,
};