@pronto-tools-and-more/components-renderer 5.3.1 → 5.4.0
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
@@ -10,6 +10,13 @@ export const renderElement = (element) => {
|
|
10
10
|
};
|
11
11
|
}
|
12
12
|
if (element.tag) {
|
13
|
+
if (typeof element.tag === "function") {
|
14
|
+
const vnode = element.tag({
|
15
|
+
...element.props,
|
16
|
+
children: element.children,
|
17
|
+
});
|
18
|
+
return renderElement(vnode);
|
19
|
+
}
|
13
20
|
const hasComplexChildren = HasComplexChildren.hasComplexChildren(element);
|
14
21
|
const renderedChildren = hasComplexChildren
|
15
22
|
? element.children.map(renderElement)
|