slate-schema-violations
A set of constants for the built-in violations in a Slate schema.
Example
Exports
CHILD_OBJECT_INVALID
CHILD_OBJECT_INVALID
Raised when the object
property of a child node is invalid.
CHILD_REQUIRED
CHILD_REQUIRED
Raised when a child node was required but none was found.
CHILD_TYPE_INVALID
CHILD_TYPE_INVALID
Raised when the type
property of a child node is invalid.
CHILD_UNKNOWN
CHILD_UNKNOWN
Raised when a child was not expected but one was found.
FIRST_CHILD_OBJECT_INVALID
FIRST_CHILD_OBJECT_INVALID
Raised when the object
property of the first child node is invalid, when a specific first
rule was defined in a schema.
FIRST_CHILD_TYPE_INVALID
FIRST_CHILD_TYPE_INVALID
Raised when the type
property of the first child node is invalid, when a specific first
rule was defined in a schema.
LAST_CHILD_OBJECT_INVALID
LAST_CHILD_OBJECT_INVALID
Raised when the object
property of the last child node is invalid, when a specific last
rule was defined in a schema.
LAST_CHILD_TYPE_INVALID
LAST_CHILD_TYPE_INVALID
Raised when the type
property of the last child node is invalid, when a specific last
rule was defined in a schema.
NODE_DATA_INVALID
NODE_DATA_INVALID
Raised when the data
property of a node contains an invalid entry.
NODE_IS_VOID_INVALID
NODE_IS_VOID_INVALID
Raised when the isVoid
property of a node is invalid.
NODE_MARK_INVALID
NODE_MARK_INVALID
Raised when one of the marks in a node is invalid.
NODE_TEXT_INVALID
NODE_TEXT_INVALID
Raised when the text content of a node is invalid.
PARENT_OBJECT_INVALID
PARENT_OBJECT_INVALID
Raised when the object
property of the parent of a node is invalid, when a specific parent
rule was defined in a schema.
PARENT_TYPE_INVALID
PARENT_TYPE_INVALID
Raised when the type
property of the parent of a node is invalid, when a specific parent
rule was defined in a schema.
Last updated