j-templates 7.0.10 → 7.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -142,8 +142,13 @@ exports.DOMNodeConfig = {
142
142
  target.replaceChildren(...children);
143
143
  },
144
144
  reconcileChildren(target, children) {
145
- if (children.length === 0 || !target.firstChild) {
146
- target.replaceChildren(...children);
145
+ if (!target.firstChild) {
146
+ for (let x = 0; x < children.length; x++)
147
+ target.appendChild(children[x]);
148
+ return;
149
+ }
150
+ if (children.length === 0) {
151
+ target.replaceChildren();
147
152
  return;
148
153
  }
149
154
  let actualNode = target.firstChild;
package/Node/vNode.js CHANGED
@@ -143,8 +143,7 @@ function StaticChildren(vnode, children) {
143
143
  const childrenScope = Store_1.ObservableScope.Create(WrapStaticChildren(vnode.injector, children));
144
144
  vnode.scopes.push(childrenScope);
145
145
  const child = Store_1.ObservableScope.Peek(childrenScope);
146
- const type = typeof child;
147
- switch (type) {
146
+ switch (typeof child) {
148
147
  case 'string': {
149
148
  const node = vNode.Create({
150
149
  type: "text",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "j-templates",
3
- "version": "7.0.10",
3
+ "version": "7.0.12",
4
4
  "description": "j-templates",
5
5
  "license": "MIT",
6
6
  "repository": "https://github.com/TypesInCode/jTemplates",