You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The implementation of this new content relationship field has been added to the latest beta version.
To use it, you can use the following configuration:
"frontMatter.taxonomy.contentTypes": [
{
"name": "project",
"pageBundle": false,
"fields": [
{
"title": "Title",
"name": "title",
"type": "string",
"required": true
},
{
"title": "Session",
"name": "session",
"type": "contentRelationship", // This is the new field type"contentTypeName": "session", // Name of the content-type to link"contentTypeValue": "slug", // The type of link/value you want to add. This can be slug, or path. "required": true
},
{
"title": "Session path",
"name": "sessionPath",
"type": "contentRelationship",
"contentTypeName": "session",
"contentTypeValue": "path",
"required": true
}
]
}
]
Activity
#585 - Added content relationship field
estruyf commentedon May 17, 2023
The implementation of this new content relationship field has been added to the latest beta version.
To use it, you can use the following configuration:
@adrian-ub, feel free to give it a try.
estruyf commentedon May 17, 2023
adrian-ub commentedon May 20, 2023
@estruyf thanks for the early development, I have tested the implementation, it works correctly when the slug en property is set in the content
configuration in json file:
Content without field slug
With field slug:
Example: https://github.com/adrian-ub/experiment-relationship-fronmatter
try to do it with pageBundle, but it gets me information from another contentType
Example: https://github.com/adrian-ub/site-content
#585 - Fix empty slugs
estruyf commentedon May 23, 2023
I just did a minor fix to generate the slugs only in memory. That way, it will not get the
undefinedvalue.To use it, first run the
Front Matter: Clear cachecommand; once you run that, it will reinitialize the cache and the issue should be fixed.