From d460bb42f053e1fcd98966b63b1e843e21eae8b7 Mon Sep 17 00:00:00 2001 From: Johan Davidsson Date: Tue, 12 Apr 2022 17:55:26 +0200 Subject: [PATCH] Doc serializing fix (#4937) Fixing a never ending recursive function in the serializing documentation. --- docs/concepts/10-serializing.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/concepts/10-serializing.md b/docs/concepts/10-serializing.md index 551ddb895..f71d3478a 100644 --- a/docs/concepts/10-serializing.md +++ b/docs/concepts/10-serializing.md @@ -171,14 +171,14 @@ const deserialize = (el, markAttributes = {}) => { const nodeAttributes = { ...markAttributes } - // define attibutes for text nodes + // define attributes for text nodes switch (el.nodeName) { case 'strong': nodeAttributes.bold = true } const children = Array.from(el.childNodes) - .map(node => deserialize(el, nodeAttributes)) + .map(node => deserialize(node, nodeAttributes)) .flat() if (children.length === 0) {