-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Description
- We will create an extension of Unist
- We want to define nodes for each "tag", where the tags are given abstract (i.e. not specifically HTML) names - see https://github.com/Financial-Times/cp-content-pipeline/blob/main/packages/schema/src/tags/index.ts#L37
e.g.
interface RecommendLink <: Parent {
type: "element"
recommendLinkId: string // these are taken from the XML attributes
title: string
children: [Element | Comment | Text] // TODO: do we want to define this strictly, or allow elements?
}
- We are not going to implement the
<experimental>tag. Things that are currently being published inside that tag should have definitions.- maybe if we need this kind of functionality, we should introduce a property. But lets not.
- For references, CP will still iterate through the AST to create the references array
- This repo can provide Node definitions for "complete" nodes (i.e. a tweet with all teh embed stuff)
- we can also provide helper functions to get the data (e.g. given a tweet ID, get the embed), which can be used in both CP and Spark Preview if required
- somehow in our node definitions, differentiate between things which have an ID OR content
Metadata
Metadata
Assignees
Labels
No labels