From 0528f48944fe795c9ce21ea39633c5c85733f3b9 Mon Sep 17 00:00:00 2001 From: Charlotte Date: Mon, 11 Sep 2023 17:52:37 +0100 Subject: [PATCH] docs: add todos for next steps --- dotcom-rendering/src/model/enhanceBlocks.ts | 3 +++ dotcom-rendering/src/server/index.article.apps.ts | 3 +++ 2 files changed, 6 insertions(+) diff --git a/dotcom-rendering/src/model/enhanceBlocks.ts b/dotcom-rendering/src/model/enhanceBlocks.ts index 35665590d88..a3836250540 100644 --- a/dotcom-rendering/src/model/enhanceBlocks.ts +++ b/dotcom-rendering/src/model/enhanceBlocks.ts @@ -96,6 +96,9 @@ type Options = { promotedNewsletter: Newsletter | undefined; }; +// TODO - add consideration of rendering target / platform +// so that we can add app-only enhancers + // IMPORTANT: the ordering of the enhancer is IMPORTANT to keep in mind // example: enhanceInteractiveContentElements needs to be before enhanceNumberedLists // as they both effect SubheadingBlockElement diff --git a/dotcom-rendering/src/server/index.article.apps.ts b/dotcom-rendering/src/server/index.article.apps.ts index af57912c22a..401b27dbbee 100644 --- a/dotcom-rendering/src/server/index.article.apps.ts +++ b/dotcom-rendering/src/server/index.article.apps.ts @@ -6,6 +6,9 @@ import { renderArticle } from './render.article.apps'; export const handleAppsArticle: RequestHandler = ({ body }, res) => { recordTypeAndPlatform('article', 'apps'); + + // TODO - add renderingTarget so that we can enhance + // blocks specifically for Apps const article = enhanceArticleType(body); const { html, prefetchScripts } = renderArticle(article);