Closed tashburn closed 6 years ago
If you're referring to this section https://docs.slatejs.org/slate-core/schema#blocks
Then I think the documentation is correct for the sake of this example and no change is needed. type
refers to the subtype of the block, and object
refers to the subtype of the node (such as leaf
, text
, document
, block
). While, yes, you can have schema rules that dictate what sort of objects
a block
may contain, for the example where the schema says "lists contain items. items are contained in lists" the use of types
here is correct.
If that's not the case, then a larger snippet or more precise permalink might help
I'm not exactly sure what you mean. In this case I think a PR is the preferred way to bring up an issue like this, since it will be much more clear, yet just as easy to do.
You're right, this documentation is fine... my bad.
In the documentation for
Schema
, in the "blocks" section,{ nodes: ... types: ... }
Should be
{ nodes: ... objects: ... }