BaryoDev / BaryoDev/barakoCMS

Content types: field roles for title, summary, date and route, read by feed, sitemap and SEO

Open
#887 0 comments 0 reactions 0 assignees View on GitHub
core design
Dominant language
C#
Stars
6
Forks
7
Avg merge
4h 42m
Merged PRs (30d)
307

Description

The feed guesses which fields mean what: the title from `Title` or `Name`, the description from `Excerpt`, `Summary`, `Description` or `Body`, `barakoCMS/Features/Public/FeedEndpoint.cs:83-84`. The link comes from server config `Feeds:Paths:{type}` (`FeedEndpoint.cs:66`), which the sitemap reads too (`barakoCMS/Features/Public/SitemapEndpoint.cs:72`). SEO guesses with its own list, `barakoCMS/Features/Seo/SeoFields.cs:145`. barakoPress builds its own RSS, so there are now two feeds.

### Why it is too specific

It works for the blog blueprint's field names. An events site with `EventName` and `Teaser`, a school with `Headline` and `Intro`, or a clinic writing field names in another language gets empty or wrong feed items. The link template sits in a server config file, so each new site or path needs an operator, not an editor.

### The general concept

Field roles on the content type: which field is the title, summary, date and image, plus a route template. They are found the way the slug field is found, with today's names as the fallback. Feed, sitemap, search and SEO all read the same roles, and the renderer can read them too instead of building its own feed logic.

### Where it lives

Core: the content type model and the public feed, sitemap and SEO code.

### Compatibility

Released. Additive: a type without roles keeps today's guessing, and `Feeds:Paths:{type}` stays as the fallback for the route template. It adds optional fields to the content type JSON, so the HTTP contract does not break. Stored types need no migration.

### Done when

- A type whose title field is `EventName`, with the title role set, produces feed items with that title, and a test showing that fails before the change.
- A route template on the type is used by the feed and the sitemap ahead of `Feeds:Paths`.
- Types without roles produce the same feed as today.

Found in the too specific sweep of 15 September 2026.

Contributor guide

Open the contributing guide

Research direction

Start with the content type model, then trace field selection in barakoCMS/Features/Public/FeedEndpoint.cs, barakoCMS/Features/Public/SitemapEndpoint.cs, and barakoCMS/Features/Seo/SeoFields.cs. Compare these paths with the existing slug-field lookup and the barakoPress RSS implementation. Done means role-based title and route behavior is covered by tests, while types without roles retain current feed output and Feeds:Paths remains the route fallback.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api, backend, content
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.