1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-08-12 02:03:59 +02:00

Fix typos in error messages (#5179)

This commit is contained in:
Oli
2022-11-08 12:37:34 +00:00
committed by GitHub
parent 469bec3d04
commit e61678da14

View File

@@ -29,14 +29,14 @@ export const Slate = (props: {
const [context, setContext] = React.useState<SlateContextValue>(() => {
if (!Node.isNodeList(value)) {
throw new Error(
`[Slate] value is invalid! Expected a list of elements` +
`but got: ${Scrubber.stringify(value)}`
`[Slate] value is invalid! Expected a list of elements but got: ${Scrubber.stringify(
value
)}`
)
}
if (!Editor.isEditor(editor)) {
throw new Error(
`[Slate] editor is invalid! you passed:` +
`${Scrubber.stringify(editor)}`
`[Slate] editor is invalid! You passed: ${Scrubber.stringify(editor)}`
)
}
editor.children = value