Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enabledNodeTypes documentation error #2173

Open
caillou opened this issue Feb 14, 2024 · 0 comments
Open

enabledNodeTypes documentation error #2173

caillou opened this issue Feb 14, 2024 · 0 comments

Comments

@caillou
Copy link

caillou commented Feb 14, 2024

When reading the following documentation, we can see this:

enabledNodeTypes?: (
  "blockquote" | "hr" | "table" | "document" | "paragraph" | 
  "heading-1" | "heading-2" | "heading-3" | "heading-4" | "heading-5" | 
  "heading-6" | "ordered-list" | "unordered-list" | "list-item" | 
  "embedded-entry-block" | "embedded-asset-block" | "embedded-resource-block" | 
  "table-row" | "table-cell" | "table-header-cell" | 
  "hyperlink" | "entry-hyperlink" | "asset-hyperlink" | "resource-hyperlink" |
   "embedded-entry-inline" | "embedded-resource-inline"
)[]

https://contentful.github.io/contentful-management.js/contentful-management/11.16.0/interfaces/ContentTypeFieldValidation.html#enabledNodeTypes

Note that this list contains the following types: table-row, table-cell, table-header-cell.

When trying to set these types, I got the following error from the API:

Error: The property "validations.0.enabledNodeTypes.15" on the field "content" 
must be one of [
  "heading-1", "heading-2", "heading-3", "heading-4", "heading-5", "heading-6", 
  "ordered-list", "unordered-list", "hr", "blockquote", "table", "embedded-entry-block", 
  "embedded-asset-block", "hyperlink", "entry-hyperlink", "asset-hyperlink", 
  "embedded-entry-inline"
].

This list does not contain any of these types.

This might be an error in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant