Extend content first to be used by other modules / out of routes

Created on 18 July 2025, 9 days ago

Problem/Motivation

Currently content first works perfectly

Technically, all the content first code is generated in a route controller. Moving the generation logic to a Drupal service allows to be used by other modules , plus adding more funcionality besides Drupal Routes.

The motivation to provide this functionality is being able to provide a token that renders content first markdown, to be used by n8n/AI.

Proposed resolution

Move all logic that generates the HTML and markdown to a service named content_first.build.
This service will return a class named RenderedCOntent that will have methods to get HTML, Xpath, and markdown.

Feature request
Status

Active

Version

1.0

Component

Code

Created by

🇪🇸Spain omarlopesino

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024